Description Usage Arguments Value Examples
View source: R/find_rating_segment.R
Search function in Childrecordings class This search function will help you to provide file name and time windows for common coding in raters
1 2 3 4 5 6 7 | find.rating.segment(
ChildRecordings,
recording_filename,
annotators = NULL,
range_from = NULL,
range_to = NULL
)
|
ChildRecordings |
: a ChildRecordings class |
recording_filename |
: a wav file name to consider |
annotators |
: an optional argument listing the annotators to consider |
range_from |
: an optional time window to restrain the search from |
range_to |
: an optional time window to restrain the search to |
A data.frame containing sections that have been annotated by several annotations
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 | ## Not run:
library(ChildRecordsR)
path = "/mnt/94707AA4707A8CAC/CNRS/corpus/vandam-daylong-demo"
CR = ChildRecordings(path)
# if no time windows is specified, this function will only return at table for all the know raters
# To work, all annotators must have at least one common annotation segment.
find.rating.segment(CR, "BN32_010007.mp3")
# However, if a time window is provided, this function will find all the data that
# overlaps with the time window provided.
Wav_file_name = "BN32_010007.mp3"
t1 = 500000
t2 = 500000*2
find.rating.segment(CR, Wav_file_name, range_from = t1, range_to = t2)
# finding segments on wav file for designated rater
raters <- c("its", "vtc")
find.rating.segment(CR,"Wav_file_name", raters)
# finding segments on wav file for the designated windows in second and rater
search <- find.rating.segment(CR,"Wav_file_name", raters, range_from = t1, range_to = t2)
# try to analyse a larger number of file
wave_file <- unique(CR$all.meta$filename) # get all the wav files
raters <- c("its", "vtc") # Define raters you are interested in
# bind all the results
search2 <- data.frame()
for (file in wave_file[1:10]){
print(file)
search2 <- rbind(search2, find.rating.segment(CR, file, raters)) # could take some time
}
head(search2)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.