powered by
Internal soundgen function called by getSurprisal. Estimates the unexpectedness or "surprisal" of the last element of input vector.
getSurprisal
getSurprisal_vector(x)
numeric vector representing the time sequence of interest, eg amplitudes in a frequency bin over multiple STFT frames
# NOT RUN { x = c(rep(1, 3), rep(0, 4), rep(1, 3), rep(0, 4), rep(1, 3), 0, 0) soundgen:::getSurprisal_vector(x) soundgen:::getSurprisal_vector(c(x, 1)) soundgen:::getSurprisal_vector(c(x, 13)) # }
Run the code above in your browser using DataLab