Skip to content

docs: clarify R CMD check NOTE for .. prefix#7826

Open
venom1204 wants to merge 6 commits into
masterfrom
issue4741
Open

docs: clarify R CMD check NOTE for .. prefix#7826
venom1204 wants to merge 6 commits into
masterfrom
issue4741

Conversation

@venom1204

Copy link
Copy Markdown
Contributor

closes #4741

in this pr i add teh docs fix for the issue

  • document R CMD check NOTE when using the .. prefix
  • add guidance for package developers
  • include globalVariables(), with=FALSE, and env= alternatives

Comment thread man/special-symbols.Rd Outdated
Comment thread vignettes/datatable-programming.Rmd Outdated
}
```

The `..` prefix (for example, `DT[, ..cols]`) looks up a variable in the calling scope. In R packages, this triggers an `R CMD check` NOTE. To avoid this, set the variable to `NULL` inside the function:

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we could additionally mention that it does not work when nested in expressions, pointing to use env in such cases

Comment thread vignettes/datatable-importing.Rmd Outdated

@ben-schwen ben-schwen left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed the things that didn't work. @jangorecki feel free to merge once you are satisfied!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

how to avoid check NOTE for ..variables in j?

3 participants