View source: R/validate-subject.R
| validate_subject | R Documentation |
Check against existence, validity, and consistency
subject |
subject ID (character), or |
method |
validation method, choices are |
verbose |
whether to print out the validation messages |
version |
data version, choices are |
A list of nested validation results. The validation process consists of the following parts in order:
paths)paththe subject's root folder
paththe subject's 'RAVE' folder (the 'rave' folder under the root directory)
raw_paththe subject's raw data folder
data_patha directory storing all the voltage, power, phase data (before reference)
meta_pathmeta directory containing all the electrode coordinates, reference table, epoch information, etc.
reference_patha directory storing calculated reference signals
preprocess_patha directory storing all the preprocessing information
cache_path (low priority)data caching path
freesurfer_path (low priority)subject's 'FreeSurfer' directory
note_path (low priority)subject's notes
pipeline_path (low priority)a folder containing all saved pipelines for this subject
preprocess)electrodes_setwhether the subject has a non-empty electrode set
blocks_setwhether the session block length is non-zero
sample_rate_setwhether the raw sampling frequency is set to a valid, proper positive number
data_importedwhether all the assigning electrodes have been imported
notch_filteredwhether all the 'LFP' and 'EKG' signals have been 'Notch' filtered
has_waveletwhether all the 'LFP' signals are wavelet-transformed
has_referenceat least one reference has been generated in the meta folder
has_epochat least one epoch file has been generated in the meta folder
has_electrode_filemeta folder has electrodes.csv file
meta)meta_data_validthis item only exists when the previous preprocess validation is failed or incomplete
meta_electrode_tablethe electrodes.csv file in the meta folder has correct format and consistent electrodes numbers to the preprocess information
meta_reference_xxx(xxx will be replaced with actual reference names) checks whether the reference table contains all electrodes and whether each reference data exists
meta_epoch_xxx(xxx will be replaced with actual epoch names) checks whether the epoch table has the correct formats and whether there are missing blocks indicated in the epoch files
voltage_data*)voltage_preprocessingwhether the raw preprocessing voltage data are valid. This includes data lengths are the same within the same blocks for each signal type
voltage_datawhether the voltage data (after 'Notch' filters) exist and readable. Besides, the lengths of the data must be consistent with the raw signals
power_phase_data*)power_datawhether the power data exists for all 'LFP' signals. Besides, to pass the validation process, the frequency and time-point lengths must be consistent with the preprocess record
power_datasame as power_data but for the phase data
epoch_tables*)One or more sub-items depending on the number of epoch tables. To pass the validation, the event time for each session block must not exceed the actual signal duration. For example, if one session lasts for 200 seconds, it will invalidate the result if a trial onset time is later than 200 seconds.
reference_tables*)One or more sub-items depending on the number of reference tables. To pass the validation, the reference data must be valid. The inconsistencies, for example, missing file, wrong frequency size, invalid time-point lengths will result in failure
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.