Learn R Programming

guess (version 0.7.0)

log_likelihood: Calculate log-likelihood for transition data

Description

Calculate log-likelihood for transition data

Usage

log_likelihood(params, data)

Value

scalar log-likelihood

Arguments

params

numeric vector of length 4 (nodk) or 8 (dk)

data

numeric vector of transition counts

Examples

Run this code
params <- c(0.4, 0.3, 0.3, 0.25)
data <- c(x00 = 10, x01 = 5, x10 = 3, x11 = 12)
log_likelihood(params, data)

Run the code above in your browser using DataLab