Hey all,
I am running R CMD check using devtools::check()
 for my package and I encountered the following NOTE in the check:
* checking R code for possible problems ... NOTE
prep: no visible global function definition for 'one_of'
The only place in which I use one_of
 in prep()
 is with this line:
raw_data <- dplyr::select(raw_data, -one_of(drop_vars))
Does anyone knows how can I solve this NOTE
?
Bellow is my DESCRIPTION
 and NAMESPACE
 files.
Any help would be greatly appreciated
I also asked this in StackoverflowÂ
http://stackoverflow.com/questions/32069800/no-visible-global-function-definition-for-one-of
Best,
Ayala
Here is how my DESCRIPTION
 file looks like:
Package: prepdat
Title: xxx
Version: 0.0.0.9000
Authors@R: person("Ayala S.", "Allon", email = "ayala...@gmail.com", role = c("aut", "cre"))
Description:xxx
Depends: R (>= 3.0.3)
License: GPL-3
LazyData: true
Imports: dplyr (>= 0.4.2),
reshape2 (>= 1.4.1),
psych(>= 1.5.4)
Suggests: knitr,
testthat
And here is how my NAMESPACE
 file looks like
importFrom(dplyr,"%>%")
importFrom(psych,"harmonic.mean")
exportPattern("^[^\\.]")
raw_data <- dplyr::select(raw_data, -
dplyr::one_of(drop_vars))
Or add dplyr to your depends or imports in the DESCRIPTION file. But since it sounds like you are using dplyr only for an example, I would probably add it to the suggested field, and use the code I provided above.
Best,
Tal
--
You received this message because you are subscribed to the Google Groups "Israel R User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to israel-r-user-g...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
raw_data <- select(raw_data, -
dplyr::one_of(drop_vars))To unsubscribe from this group and stop receiving emails from it, send an email to israel-r-user-group+unsub...@googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to israel-r-user-g...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "Israel R User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to israel-r-user-g...@googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to israel-r-user-group+unsub...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "Israel R User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to israel-r-user-group+unsub...@googlegroups.com.