markNA {PAMscapes}R Documentation

Mark NA Values by Time and Frequency

Description

Marks values within a soundscape dataframe as NA according to provided time and (optionally) frequency values

Usage

markNA(x, na, by = NULL)

Arguments

x

dataframe of soundscape data to mark NAs in

na

dataframe listing areas to mark NA. Must have columns start and end in UTC listing time ranges. Can also have columns freqMin and freqMax to also have accompanying frequency ranges, otherwise all frequency values within the time range will be set to NA

by

optional column name in both x and na if only certain rows of na should apply to certain rows of x (e.g. if these contain multiple deployments overlapping in time, a "DeploymentName" column can be used to only mark appropriate times)

Value

same dataframe as x but with some values replaced with NA

Author(s)

Taiki Sakai taiki.sakai@noaa.gov

Examples

manta <- checkSoundscapeInput(system.file('extdata/MANTAExampleSmall1.csv', package='PAMscapes'))
naDf <- data.frame(start=min(manta$UTC),
                   end=max(manta$UTC),
                   freqMin=100,
                   freqMax=500)
plotHourlyLevel(manta)
plotHourlyLevel(markNA(manta, na=naDf))


[Package PAMscapes version 0.6.0 Index]