| data_preview | R Documentation |
Open a data frame in R's viewer. Data can be supplied as a file path, a data
frame, or loaded from an options file (with the same prompt flow as
artma() when no options are given).
data_preview(
data = NULL,
options = NULL,
options_dir = NULL,
preprocess = TRUE
)
data |
[character, data.frame, optional] Either |
options |
[character, optional] Name of the options file (with or
without |
options_dir |
[character, optional] Directory containing the options
file. If |
preprocess |
[logical, optional] If |
Three data sources are supported:
Path: pass a length-one character path to a data file. With
preprocess = FALSE, the file is read without loading options
(raw read). With preprocess = TRUE, options are loaded and the
full pipeline is applied.
Data frame: pass a data frame. With preprocess = FALSE,
it is viewed as-is. With preprocess = TRUE, options are loaded
and preprocess + compute are applied before viewing.
NULL: data comes from the chosen options file (same
"select or create options file" flow as artma() with empty
arguments). With preprocess = TRUE (default), the full pipeline
(read, preprocess, compute) is run. With preprocess = FALSE, only
the data as read from file (with column standardization from options) is
shown, without preprocessing or computed columns.
In non-interactive mode, when data is NULL and options
is NULL, no viewer is shown (consistent with artma()).
Invisible NULL. Opens the data in the standard R viewer
(utils::View()). When no viewer is available (a non-interactive
session, or a Unix session with no reachable display), the first rows are
printed instead.
artma - Run meta-analysis methods
prepare_data() - Prepare data manually
options_load - Load options
## Not run:
# Preview data from options file (prompts for file if NULL)
data_preview(options = "my_analysis.yaml")
# Preview raw file without loading options
data_preview("/path/to/data.csv", preprocess = FALSE)
# Preview preprocessed data from a path (uses options for standardization)
data_preview("/path/to/data.csv", options = "my_analysis.yaml")
# Preview a data frame as-is
data_preview(mtcars, preprocess = FALSE)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.