Learn R Programming

qtlmt (version 0.1-1)

sureEst: SURE model parameter estimation

Description

Estimate parameters in a SURE model.

Usage

sureEst(y,x,v,sigma,iter=250,tol=1e-8)

Arguments

y
n by p matrix, whose columns are dependent variables.
x
n by m matrix, whose columns are predictor variables to select from.
v
list; v[[j]] indicates which x's in the model for y[,j].
sigma
residual variance-covarance matrix (if given).
iter
maximum number of iterations in a numerical process to estimate model parameters.
tol
convergence tolerance.

Value

  • a list with the following components:
  • loglik:log-likelihood of the model
  • b:estimates of model coefficients
  • sigma:estimated residual variance-covariance

See Also

sureStep

Examples

Run this code
data(etrait)
x<- as.matrix(3/2-mdat)
y<- as.matrix(traits)[,1:3]
v<- list()
upper<- list()
for(k in 1:ncol(y)){
   v[[k]]<- numeric(0)
   upper[[k]]<- 1:ncol(x)
}
g<- sureStep(y, x, v=v, upper=upper, k=19, direction="both",
   iter=250, max.terms=250, steps=2000, tol=1e-6)
ge<- sureEst(y, x, v=g$v, iter=250, tol=1e-8)

Run the code above in your browser using DataLab