testranfix.asrtests | R Documentation |
asreml
and records the result in an asrtests.object
.Tests for a single term, using a REML ratio test (REMLRT) for a random term or based
on Wald statistics for a fixed term. The term must be in the fitted model.
A random term is removed from the model fit and a REMLRT is
performed using REMLRT.asreml
. It compares the fit of the model in
asreml.obj
and the newly fitted model without the term
.
If the newly fitted model is retained, any boundary terms are then removed
using rmboundary.asrtests
.
For a fixed term, the probability of the Wald
statistics is extracted from the pseudo-anova table produced by
wald.asreml
. If this is available in the asrtests.object
, it is
used; otherwise wald.asreml
is called to add it to the
asrtests.object
. Whether nonsignificant terms are dropped is controlled
by drop.ran.ns
for random terms and drop.fix.ns
for fixed terms. A row is
added to the test.summary
data.frame
for the term that is tested.
## S3 method for class 'asrtests'
testranfix(asrtests.obj, term=NULL, alpha = 0.05,
allow.unconverged = TRUE, allow.fixedcorrelation = TRUE,
checkboundaryonly = FALSE,
drop.ran.ns = TRUE, positive.zero = FALSE,
bound.test.parameters = "none",
bound.exclusions = c("F","B","S","C"), REMLDF = NULL,
drop.fix.ns = FALSE, denDF="numeric", dDF.na = "none",
dDF.values = NULL, IClikelihood = "none",
trace = FALSE, update = TRUE,
set.terms = NULL, ignore.suffices = TRUE,
bounds = "P", initial.values = NA, ...)
asrtests.obj |
An |
term |
A single model term that is valid in |
alpha |
The significance level for the test. |
allow.unconverged |
A |
allow.fixedcorrelation |
A |
checkboundaryonly |
If |
drop.ran.ns |
A |
positive.zero |
Indicates whether the hypothesized values for the
variance components being tested are on the boundary
of the parameter space. For example, this is true
for positively-constrained variance components that,
under the reduced model, are zero. This argument does
not need to be set if |
bound.test.parameters |
Indicates whether for the variance components
being tested, at least some of the hypothesized values
are on the boundary of the parameter space.
The possibilities are |
bound.exclusions |
A |
REMLDF |
A |
drop.fix.ns |
A |
denDF |
Specifies the method to use in computing approximate denominator
degrees of freedom when |
dDF.na |
The method to use to obtain substitute denominator degrees of freedom.
when the numeric or algebraic methods produce an |
dDF.values |
A |
IClikelihood |
A |
trace |
If TRUE then partial iteration details are displayed when ASReml-R functions are invoked; if FALSE then no output is displayed. |
update |
If |
set.terms |
A character vector specifying the terms that are to have
bounds and/or initial values set prior to fitting.
The names must match those in the |
ignore.suffices |
A logical vector specifying whether the suffices of the
|
bounds |
A |
initial.values |
A character vector specifying the initial values for
the terms specified in |
... |
Further arguments passed to |
An asrtests.object
containing the components (i) asreml.obj
,
(ii) wald.tab
, and (iii) test.summary
.
If the term
is not in the model, then the supplied asreml
object will be returned. Also, reml.test
will have the likelihood
ratio and the p-value set to NA
and the degrees of freedom to zero.
Similarly, the row of test.summary
for the term
will have
its name, DF set to NA, p-value set to NA
, and action set to Absent.
Chris Brien
Kenward, M. G., & Roger, J. H. (1997). Small sample inference for fixed effects from restricted maximum likelihood. Biometrics, 53, 983-997.
asremlPlus-package
, as.asrtests
,
chooseModel.asrtests
, REMLRT.asreml
,
rmboundary.asrtests
,
newfit.asreml
, changeModelOnIC.asrtests
,
changeTerms.asrtests
, reparamSigDevn.asrtests
## Not run:
data(Wheat.dat)
current.asr <- asreml(yield ~ Rep + WithinColPairs + Variety,
random = ~ Row + Column + units,
residual = ~ ar1(Row):ar1(Column),
data=Wheat.dat)
current.asrt <- as.asrtests(current.asr, NULL, NULL)
current.asrt <- rmboundary(current.asrt)
# Test nugget term
current.asrt <- testranfix(current.asrt, "units", positive=TRUE)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.