xportr_options | R Documentation |
There are two mechanisms for working with options for xportr. One is the
options()
function, which is part of base R, and the other is the
xportr_options()
function, which is in the xportr package. The reason for
these two mechanisms is has to do with legacy code and scoping.
The options()
function sets options globally, for the duration of the R
process. The getOption()
function retrieves the value of an option. All
xportr related options of this type are prefixed with "xportr."
.
xportr_options(...)
... |
Options to set, with the form |
options()
defaults to "dataset"
The name of the domain "name" column in dataset metadata.
defaults to "label"
The column noting the dataset label in dataset metadata.
defaults to "dataset"
The name of the domain "name" column in variable metadata.
defaults to "variable"
The name of the variable "name" in variable metadata.
defaults to "type"
The name of the variable type column in variable metadata.
defaults to "label"
The name of the variable label column in variable metadata.
defaults to "length"
The name of the variable length column in variable metadata.
defaults to "order"
The name of the variable order column in variable metadata.
defaults to "format"
The name of the variable format column in variable metadata.
defaults to "none"
The default argument for the 'verbose' argument for xportr_format
.
defaults to "none"
The default argument for the 'verbose' argument for xportr_label
.
defaults to "none"
The default argument for the 'verbose' argument for xportr_length
.
defaults to "label"
The default argument for the 'verbose' argument for xportr_type
.
defaults to "character"
The default character vector used to explicitly coerce R classes to character XPT types.
defaults to c("character", "char", "text", "date", "posixct", "posixt", "datetime", "time", "partialdate", "partialtime", "partialdatetime", "incompletedatetime", "durationdatetime", "intervaldatetime")
The default character vector used to explicitly coerce R classes to character XPT types.
defaults to c("integer", "numeric", "num", "float")
The default character vector used to explicitly coerce R classes to numeric XPT types.
defaults to c("integer", "float", "numeric", "posixct", "posixt", "time", "date", "hms")
The default character vector used to explicitly coerce R classes to numeric XPT types.
xportr_options()
Alternative to the options()
, the xportr_options()
function can be used to set the options.
The xportr_options()
function also returns the current options when a character vector of
the options keys are passed into it. If nothing is passed into it, it returns the state of all xportr options.
xportr_options("xportr.df_label")
xportr_options(xportr.df_label = "data_label", xportr.label = "custom_label")
xportr_options(c("xportr.label", "xportr.df_label"))
xportr_options()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.