| plot.agd | R Documentation |
This method renders scatter plots iteratively and interactively using results from an agd object.
## S3 method for class 'agd'
plot(x, ..., id)
x |
Required: an agd object. |
... |
Optional: arguments to be passed to methods. Note: currently not used. |
id |
Optional: a vector representing participant IDs in |
Returns ggplot2 objects invisibly.
# Initialize agd R6 class
agd_data <- agd$new(
id = "jane-canuck",
age = 10,
agd_lfe = system.file("extdata", "jane-canuck-lfe.agd", package = "chms"),
agd_nml = system.file("extdata", "jane-canuck-nml.agd", package = "chms"),
epoch_length = 15,
day_max = 2,
sleep_algo = "barreira",
non_wear_algo = "barreira"
)
# Run data processing pipeline (load, clean, classify and summarize data)
agd_data$run()
# Plot data
plot(agd_data)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.