loglinll {bayess}R Documentation

Log of the likelihood of the log-linear model

Description

This function provides a direct computation of the logarithm of the likelihood of a standard log-linear model, as defined in Chapter 4.

Usage

loglinll(beta, y, X)

Arguments

beta

coefficient of the logit model

y

vector of binary response variables

X

covariate matrix

Value

returns the logarithmic value of the logit likelihood for the data y, covariate matrix X and parameter vector beta

Examples

X=matrix(rnorm(20*3),ncol=3)
beta=c(3,-2,1)
y=rpois(20,exp(X%*%beta))
loglinll(beta, y, X)

[Package bayess version 1.6 Index]