View source: R/RAR_Spectrum_plot.r
RAR_Spectrum_plot | R Documentation |
This function plots the estimated and smoothed power spectrum generated from RAR_Spectrum().
RAR_Spectrum_plot(rar_spectrum, id_vals = NULL)
rar_spectrum |
default output from RAR_Spectrum(). |
id_vals |
character vector to print plots for each participant specified. Default is NULL. |
Haoyi Fu, Jessica Graves
data(age_wise)
d <- age_wise[age_wise$id==1,]
rar_ex <- RAR(d, act, date_time)
spec <- RAR_Spectrum(rar_ex)
RAR_Spectrum_plot(spec)
# Multiple subjects
d4 <- age_wise[age_wise$id %in% c(1:4), ]
rar_ex4 <- RAR(d4, act, date_time, id_column=id)
spec4 <- RAR_Spectrum(rar_ex4, id_column=id)
RAR_Spectrum_plot(spec4, id_vals=c("1", "2")) # log scale, ids 1 and 2
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.