imp_syrinx
imports 'Syrinx' selection data from many files simultaneously.
All files must have the same columns.
imp_syrinx(path = NULL, all.data = FALSE, recursive = FALSE,
exclude = FALSE, hz.to.khz = TRUE, parallel = 1, pb = TRUE)
A single data frame with information of the selection files. If all.data argument is set to FALSE
the data
frame contains the following columns: selec, start, end, and selec.file. If sound.file.col is provided the data frame
will also contain a 'sound.files' column. If all.data is set to TRUE
then all
columns in selection files are returned.
A character string indicating the path of the directory in which to look for the text files.
If not provided (default) the function searches into the current working directory. Default is NULL
.
Logical. If TRUE
all columns in text files are returned. Default is FALSE
. Note
that all files should contain exactly the same columns in the same order.
Logical. If TRUE
the listing recurses into sub-directories.
Logical. Controls whether files that cannot be read are ignored (TRUE
). Default is FALSE
.
Logical. Controls if frequency variables should be converted from Hz (the unit used by Syrinx) to kHz (the unit used by warbleR and other bioacoustic analysis packages in R). Default if TRUE
. Ignored if all.data is TRUE
.
Numeric. Controls whether parallel computing is applied. It specifies the number of cores to be used. Default is 1 (i.e. no parallel computing).
Logical argument to control progress bar. Default is TRUE
.
Marcelo Araya-Salas (marcelo.araya@ucr.ac.cr)
imp_raven
if (FALSE) {
#load data
data(selection_files)
#save 'Raven' selection tables in the temporary directory
writeLines(selection_files[[7]], con = file.path(tempdir(), names(selection_files)[7]))
syr.dat <- imp_syrinx(all.data = FALSE)
# View(syr.dat)
#getting all the data
syr.dat <- imp_syrinx(all.data = TRUE)
# View(syr.dat)
}
Run the code above in your browser using DataLab