Learn R Programming

lintr (version 3.1.2)

T_and_F_symbol_linter: T and F symbol linter

Description

Avoid the symbols T and F, and use TRUE and FALSE instead.

Usage

T_and_F_symbol_linter()

Arguments

Tags

best_practices, consistency, default, readability, robustness, style

See Also

Examples

Run this code
# will produce lints
lint(
  text = "x <- T; y <- F",
  linters = T_and_F_symbol_linter()
)

lint(
  text = "T = 1.2; F = 2.4",
  linters = T_and_F_symbol_linter()
)

# okay
lint(
  text = "x <- c(TRUE, FALSE)",
  linters = T_and_F_symbol_linter()
)

lint(
  text = "t = 1.2; f = 2.4",
  linters = T_and_F_symbol_linter()
)

Run the code above in your browser using DataLab