the safe version of extract values from one variable require(haven) # mtcars.sas7bdat was generated from R mtcars dataset # get file path df <- system.file("extdata", "mtcars.sas7bdat", package = "createdictionary") # read in data d <- read_sas(df) # one variable dic_value_extract_one_var_safetly(d$mpg, "mpg") dic_value_extract_one_var_safetly(d$mpg, "mpg")$result
1 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.