getInit: Get and set initial parameter values for structured sparse...

Description Usage Arguments Examples

Description

The initial values for a structured sparse matrix are stored in the environment of its transformation function, where they have the name init. Random effects term structures (reTrmStruct) contain two structured sparse matrices: the transposed relative covariance factor, Lambdat, and the transposed random effects model matrix, Zt. There are getReTrm.reTrmStruct and setReTrm.reTrmStruct methods for getting and setting the initial values of these matrices directly. Setting initial values does not change the values themselves, only the initial values. Use the update.strucMatrix methods to actually update the values to the initial values.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
getInit(x, ...)

## Default S3 method:
getInit(x, ...)

## S3 method for class 'strucMatrix'
getInit(x, ...)

## S3 method for class 'function'
getInit(x, ...)

## S3 method for class 'reTrmStruct'
getInit(x, ...)

## S3 method for class 'strucParseFormula'
getInit(x, ...)

setInit(x, ...)

## Default S3 method:
setInit(x, init, ...)

## S3 method for class 'strucMatrix'
setInit(x, init, ...)

## S3 method for class 'function'
setInit(x, init, ...)

## S3 method for class 'reTrmStruct'
setInit(x, initCovar, initLoads, ...)

## S3 method for class 'strucParseFormula'
setInit(x, init, parType, ...)

Arguments

x

object

...

not yet used

init

initial value for the parameter vector

initCovar

initial value for the covariance parameter vector

initLoads

initial value for the loadings parameter vector

parType

character string giving the type of parameter to set (if parType is missing, then guidance is provided by printing available parTypes). types can be "fixef" if a fixed effects model matrix is present, "weigh" if weights parameters are present, "covar.trmName" if covariance parameters are present where "trmName" is the name of a random effects term, and "loads.trmName" if loadings are present.

Examples

1
2
3
4
5
6
set.seed(1)
m1 <- as.strucMatrix(matrix(rnorm(6), 2, 3))
m2 <- strucMatrixCompSymm(1.2, -0.2, 5)
getInit(m1)
getInit(m2)
setInit(m2, c(10, 0))

stevencarlislewalker/lme4ord documentation built on May 30, 2019, 4:43 p.m.