Entering edit mode
Kristen K Dang
▴
50
@kristen-k-dang-2922
Last seen 10.2 years ago
Dear List members,
I am using MAANOVA to fit a multi-factor ANCOVA-type model for my
data.
However, I encounter the below error when attempting to use the matest
function to run the F tests of my continuous covariates. I don't have
any
problems with this function when testing fixed factors using the same
design matrix, and model-fitted object. The traceback indicates a
problem
with the makeContrast function, but I am not doing any contrasts of
the
continuous covariates. In the method description for matest, it says
"For
testing a covariate, use a one by one contrast matrix of 1." So I also
tried the below code using a 1x1 matrix, which didn't work either. I
am
confused as to why a contrast matrix should be needed for testing
continuous covariates. Any suggestions?
test = matestdata.ma, fit.fix3, term = "v", n.perm = 100)
Error in apply(tmpL, 1, any) : dim(X) must have a positive length
> traceback()
5: stop("dim(X) must have a positive length")
4: apply(tmpL, 1, any)
3: which(apply(tmpL, 1, any))
2: makeContrast(model, term)
1: matestdata.ma, fit.fix3, term = "v", n.perm = 100)
c = matrix(1,1,1)
> c
[,1]
[1,] 1
> test = matestdata.ma, fit.fix3, term = "v", Contrast = c, n.perm =
0)
Doing F-test on observed data ...
Doing permutation. This may take a long time ...
Error: dims [product 48802] do not match the length of object [0]
In addition: Warning messages:
1: In any(parsed.formula$random) :
coercing argument of type 'double' to logical
2: In any(parsed.formula$random) :
coercing argument of type 'double' to logical
Kristen Dang
Postdoctoral Associate
Duke Human Vaccine Institute
[[alternative HTML version deleted]]