Read 'BCI2000' data file
Usage
read_bci2000(
file,
extract_path = getOption("ieegio.extract_path", NULL),
header_only = FALSE,
cache_ok = TRUE,
verbose = TRUE
)
Arguments
- file
file path to the data file
- extract_path
location to where the extracted information is to be stored
- header_only
whether to only load header data
- cache_ok
whether existing cache should be reused; default is
TRUE
. This input can speed up reading large data files; set toFALSE
to delete cache before importing.- verbose
whether to print processing messages; default is
TRUE
Value
A cached object that is readily to be loaded to memory; see
SignalDataCache
for class definition.
Examples
if( ieegio_sample_data("bci2k.dat", test = TRUE) ) {
file <- ieegio_sample_data("bci2k.dat")
x <- read_bci2000(file)
print(x)
channel <- x$get_channel(1)
plot(
channel$time,
channel$value,
type = "l",
main = channel$info$Label,
xlab = "Time",
ylab = channel$info$Unit
)
}