Skip to content

T_and_F_symbol_linter() false positive with formula syntax #2637

@IndrajeetPatil

Description

@IndrajeetPatil
library(lintr)
lint(
  text = "ivreg::ivreg(Q ~ P + D | D + F + A, data = Kmenta)", 
  linters = T_and_F_symbol_linter()
)
#> <text>:1:31: style: [T_and_F_symbol_linter] Use FALSE instead of the symbol F.
#> ivreg::ivreg(Q ~ P + D | D + F + A, data = Kmenta)
#>                              ~^

The F here corresponds to the column name:

data(Kmenta, package = "ivreg")
colnames(Kmenta)
#> [1] "Q" "P" "D" "F" "A"

Created on 2024-07-28 with reprex v2.1.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions