Learn R Programming

tcensReg (version 0.1.7)

tcensReg_gradient_sepvar: Analytic Gradient Vector for J Independent Truncated Normal Random Variables with Separate Variance

Description

Analytic Gradient Vector for J Independent Truncated Normal Random Variables with Separate Variance

Usage

tcensReg_gradient_sepvar(theta, y, X, group, a = -Inf, v = NULL)

Arguments

theta

Numeric vector numeric vector containing estimates of beta and log sigma

y

Numeric vector with the observed truncated and censored outcomes

X

Numeric design matrix

group

Character vector identifying the group membership for the independent truncated normal variables. This defines the J groups.

a

Numeric scalar indicating the truncation value

v

Numeric scalar indicating the censoring value

Value

Vector of gradient values with p-1 beta parameters and log sigma for the nth iterate