Description Usage Arguments Details Value Author(s) See Also Examples
View source: R/loglikelihood.R
Calculates the loglikelihood for an abundance datesset and a given function
1 | loglikelihood(dates, func, allowDistrBorders = FALSE)
|
dates |
vector; dates, that should be in the range of the function. |
func |
function object; a given function, for whih the loglikelihood shall be calculated. |
allowDistrBorders |
logical; If TRUE the first and last values of the dates vector will b changed by 0.00001 (first) or -0.00001(last) if the corresponding result of the function is Inf or -Inf. |
Calculates the loglikelihood for an abundance datesset and a given function by multiplying all the values given by the given function, that uses the dates given by dates.
A numeric value representing the loglikelihood.
Florian Berger <florian_berger@ymail.com>
1 2 3 4 5 | a <- c(1:10)
dates <- as.Date(a, origin = '2017-01-01')
count <- c(1,1,3,4,6,9,5,4,2,1)
dat <- data.frame(dates, count)
loglikelihood(dates = dates, func = estdist(dat))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.