I'm a PhD student, and I've been using MonitoR in RStudio to classify pumpkin toadlets vocalizations obtained with Audiomoth.
Although it is possible to classify vocalizations file by file using MonitoR, it would be very time saving if I could use the batchCorMatch function. Unfortunately, it is not working for me and I'm emailing you to know if you can enlighten me.
Here is my code.
viewSpec("20221025_100000.WAV", wl = 1024, ovlp = 80, frq.lim = c(5, 8))
t1 <- makeCorTemplate("20221025_100000.WAV", t.lim = c(3.7, 4.1), frq.lim = c(5.5, 8), name = "t1") #Zoom on the first note of the first recording
t5 <- makeCorTemplate("20221025_100000.WAV", t.lim = c(6.5, 6.8), frq.lim = c(5.5, 8), name = "t5") #Zoom on the last note of the second recording
ctemps <- combineCorTemplates(t1,t5)
cscores <- corMatch("20221025_100000.WAV", ctemps) #Correlation scores
pdetects <- findPeaks(cscores)
templateCutoff(pdetects) <- c(default = 0.07)
templateCutoff(ctemps) <- c(t1 = 0.07, t5 = 0.08)
##The following line doesn't work
detects <- batchCorMatch(dir.template = ctemps, dir.survey = "surv", warn = FALSE)
Reading in templates. . . done. Calling corMatch for NA . . . Error in getOneClip(clip, name, output, write.wav) :
clip argument seems to be a file name but no file with the name NA exists.
"surv" is a folder inside my directory with the recordings. I also tried to select the directory folder itself, but it still gave me this error. When I try corMatch it works, but not when I try batchCorMatch.