Description Usage Arguments Format Details Value
View source: R/core-repo_loader.R
Load or attach 'RAVE' a subject to current analysis context. The goal is to allow analysis and visualization to be focused on one that subject.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 | rave_load(
subject,
epoch,
reference,
before_onset,
after_onset,
electrodes,
attach = FALSE
)
rave_attach(x, ...)
## S3 method for class 'RAVERepository'
rave_attach(x, ...)
## S3 method for class 'character'
rave_attach(x, epoch, reference, before_onset, after_onset, electrodes, ...)
## S3 method for class 'RAVESubject'
rave_attach(x, epoch, reference, before_onset, after_onset, electrodes, ...)
attached_repo(test = FALSE)
rave_attached
|
subject |
character, the format is |
epoch |
character, name of epoch, located in subject's 'meta' folder,
with file name |
reference |
character, name of reference scheme, located in subject's
'meta' folder, with file name |
before_onset |
seconds before trial onset |
after_onset |
seconds after trial onset |
electrodes |
electrodes to load, if missing then default to all possible electrodes |
attach |
whether to attach loaded repository for analysis |
x |
either |
... |
passed to other methods |
test |
whether return |
An object of class ravebase_rave_attached
(inherits from ravebase_readonly
) of length 14.
rave_attached
is a list providing various of methods that
handles attached subjects. It also allows 'RAVE' modules designed for
single-subject analysis to get information of what's to be analyzed.
epoch
and reference
are located in subject's meta folder. The
folder path is "<RAVE data_path>/project/subject/rave/meta/"
. Epoch
files start with "epoch_"
, and its name is decided by the characters
following the prefix. For example, an epoch named "auditory" will have file
name "epoch_auditory.csv"
. This rule applies to reference files,
except that the prefix is "reference_"
before_onset
and after_onset
affects the amount of data
to be loaded. For example, before_onset=1
and after_onset=2
will result in total 3 seconds of data to be loaded: 1 second before trial
onset and 2 after onset. The reason to load data before onset is to leave
certain time range for baseline. If the trial lasts for 2 seconds, loading
3 seconds of data allows around 1 second to be counted into baseline.
The trial onset time for each trial is defined at column "Time"
in
the epoch file.
If attach=TRUE
, then rave_load
is equivalent to
rave_attach
.
rave_load
and rave_attach
returns loaded repository,
an instance of RAVERepository
class. attached_repo
returns currently loaded repository. If no repository loaded then it raises
errors.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.