parse_formats | R Documentation |
Useful to extract factor formatting information contained in a proc format SAS statement.
parse_formats( path_to_format_definition, ignore_keywords = c("value"), encoding = "ISO-8859-1" )
path_to_format_definition |
(string) Path to the text file to be parsed |
ignore_keywords |
A vector of keywords to be ignored when searching for the name of the variable to be formatted |
encoding |
Encoding for the text file |
A named list with format definitions
tmpfile <- tempfile() write( "proc format; value yn 1=\"yes\" 0=\"no\"; value sex 1=\"female\" 0=\"male\"; run;",tmpfile) parse_formats(tmpfile)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.