You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently in the get_newman_transmissiblity function, I am assuming an exponential distribution for the integration.
Could consider doing an empiric pdf adapting the code below:
empiricPDF <- function(fs, fspred, N) {
densfx <- stats::density(fs,
bw = 1, # individual counts
kernel = "epanechnikov",
from = 0, to = N)
# Evaluate the approx PDF at a specific point
out <- densfx$y[which.min(abs(densfx$x - fspred))] # use which.min to identify the index of the closest value, which is then taken from density y
return(out/sum(densfx$y))
}
The text was updated successfully, but these errors were encountered:
Currently in the
get_newman_transmissiblity
function, I am assuming an exponential distribution for the integration.Could consider doing an empiric pdf adapting the code below:
The text was updated successfully, but these errors were encountered: