Score: Title: Score function for Dirichlet and Multinomial models

View source: R/02_likelihood.R

ScoreR Documentation

Title: Score function for Dirichlet and Multinomial models

Description

Title: Score function for Dirichlet and Multinomial models

Usage

Score(Y, X, b, model)

Arguments

Y

matrix of count outcomes

X

matrix of covariates

b

matrix of dimensions p x q; where p = number of covariates & q = number of branches. Note: When q=1, we are conditioning the likelihood on that specific branch

model

character type of model to use for the Log Likelihood. Options are (Dirichlet Multinomial = "dirmult", Multinomial = "mult", or Dirichlet = "dir")

Details

The score function takes the derivative of the log-likelihood function. This can be used to maximize the log likelihood by setting the score to 0.

Value

The score from the model of choice


Goodgolden/LDTM documentation built on May 25, 2022, 5:25 p.m.