Learn R Programming

daarem (version 0.7)

ProbitUpdate: EM Algorithm Update for Probit Regression

Description

Function performs an EM update (both the E and M steps) of the parameters for a Probit regression model.

Usage

ProbitUpdate(beta.hat, X, y)

Arguments

beta.hat

A vector of length p. The current estimates of the regression parameters.

X

The n x p design matrix for the Probit regression model.

y

Vector of length n containing binary outcomes (either 0 or 1).

Value

A vector of length p - the updated parameter values.

See Also

ProbitSimulate, ProbitLogLik

Examples

Run this code
# NOT RUN {
n <- 200
npars <- 5
true.beta <- .5*rt(npars, df=2) + 2
XX <- matrix(rnorm(n*npars), nrow=n, ncol=npars)
yy <- ProbitSimulate(true.beta, XX)

initial.beta <- rep(0.0, npars)
new.beta <- ProbitUpdate(initial.beta, XX, yy)
# }

Run the code above in your browser using DataLab