corMatrix.corStruct(nlme)
corMatrix.corStruct()所属R语言包:nlme
Matrix of a corStruct Object
一个corStruct对象矩阵
译者:生物统计家园网 机器人LoveR
描述----------Description----------
This method function extracts the correlation matrix (or its transpose inverse square-root factor), or list of correlation matrices (or their transpose inverse square-root factors) corresponding to covariate and object. Letting S denote a correlation matrix, a square-root factor of S is any square matrix L such that S=L'L. When corr = FALSE, this method extracts L^(-t).
此方法的功能,提取相关矩阵(或转逆平方根的因素),或相应的covariate和object相关矩阵(或他们的转逆平方根因素)。让S表示相关矩阵,平方根因素S是任何方阵LS=L'L。当corr = FALSE,这种方法提取L^(-t)。
用法----------Usage----------
## S3 method for class 'corStruct'
corMatrix(object, covariate, corr, ...)
参数----------Arguments----------
参数:object
an object inheriting from class corStruct representing a correlation structure.
继承类corStruct代表相关结构的对象。
参数:covariate
an optional covariate vector (matrix), or list of covariate vectors (matrices), at which values the correlation matrix, or list of correlation matrices, are to be evaluated. Defaults to getCovariate(object).
一个可选的协变量向量(矩阵),或协向量(矩阵),在这重视相关矩阵或相关矩阵列表列表,进行评估。 getCovariate(object)默认。
参数:corr
a logical value. If TRUE the function returns the correlation matrix, or list of correlation matrices, represented by object. If FALSE the function returns a transpose inverse square-root of the correlation matrix, or a list of transpose inverse square-root factors of the correlation matrices.
一个逻辑值。如果TRUE函数返回相关矩阵或相关矩阵的名单,代表object。如果FALSE函数返回一个转逆相关矩阵的平方根,或转逆平方根因素相关矩阵列表。
参数:...
some methods for this generic require additional arguments. None are used in this method.
这个通用的一些方法需要额外的参数。没有使用这种方法。
值----------Value----------
If covariate is a vector (matrix), the returned value will be an array with the corresponding correlation matrix (or its transpose inverse square-root factor). If the covariate is a list of vectors (matrices), the returned value will be a list with the correlation matrices (or their transpose inverse square-root factors) corresponding to each component of covariate.
covariate如果是一个向量(矩阵),返回值将是一个与相应的相关系数矩阵(或它的转逆平方根因子)的阵列。如果covariate是一个向量(矩阵)的列表,返回值将是与相关矩阵(或转逆平方根因素),对应到每个组件covariate列表。
作者(S)----------Author(s)----------
Jose Pinheiro and Douglas Bates <a href="mailto:bates@stat.wisc.edu">bates@stat.wisc.edu</a>
参考文献----------References----------
in S and S-PLUS", Springer.
参见----------See Also----------
corFactor.corStruct, Initialize.corStruct
corFactor.corStruct,Initialize.corStruct
举例----------Examples----------
cs1 <- corAR1(0.3)
corMatrix(cs1, covariate = 1:4)
corMatrix(cs1, covariate = 1:4, corr = FALSE)
# Pinheiro and Bates, p. 225[皮涅伊罗和贝茨,P。 225]
cs1CompSymm <- corCompSymm(value = 0.3, form = ~ 1 | Subject)
cs1CompSymm <- Initialize(cs1CompSymm, data = Orthodont)
corMatrix(cs1CompSymm)
# Pinheiro and Bates, p. 226[皮涅伊罗和贝茨,P。 226]
cs1Symm <- corSymm(value = c(0.2, 0.1, -0.1, 0, 0.2, 0),
form = ~ 1 | Subject)
cs1Symm <- Initialize(cs1Symm, data = Orthodont)
corMatrix(cs1Symm)
# Pinheiro and Bates, p. 236 [皮涅伊罗和贝茨,P。 236]
cs1AR1 <- corAR1(0.8, form = ~ 1 | Subject)
cs1AR1 <- Initialize(cs1AR1, data = Orthodont)
corMatrix(cs1AR1)
# Pinheiro and Bates, p. 237 [皮涅伊罗和贝茨,P。 237]
cs1ARMA <- corARMA(0.4, form = ~ 1 | Subject, q = 1)
cs1ARMA <- Initialize(cs1ARMA, data = Orthodont)
corMatrix(cs1ARMA)
# Pinheiro and Bates, p. 238 [皮涅伊罗和贝茨,P。 238]
spatDat <- data.frame(x = (0:4)/4, y = (0:4)/4)
cs1Exp <- corExp(1, form = ~ x + y)
cs1Exp <- Initialize(cs1Exp, spatDat)
corMatrix(cs1Exp)
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|