To install the code, do one of the following:
- Download it then load with
source(addNewData.R)
- Load it directly from github
library(devtools, quietly=TRUE)
source_gist("https://gist.github.com/dfalster/5589956")
To use it, simply type
addNewData("dataNew.csv", myData, allowedVars)
where allowedVars
is vector of permissible variable names for the columns of myData.
thanks for creating this! i'm having an issue where the lookup table is not working correctly if the source data in the "lookupValue" vector ends with a space. i.e. it'll correctly function when looking up "source data" but not "source data ".