Learn R Programming

asremlPlus (version 2.0-2)

asrtests: Forms an object of S3-class asrtests that stores a fitted asreml object, a pseudo-anova table for the fixed and a history of changes and hypthesis testing used in obtaining the model.

Description

An object of S3-class asrtests consists of a list containing:
  1. asreml.obj: anasremlobject containing the fit of the model;
  2. wald.tab: adata.framecontaining a pseudo-anova table for the fixed terms produced bywald.asreml, which will be called ifwald.tabisNULL;
  3. test.summary: adata.framewith columnsterm,DF,denDF,pandaction. A row is added to it for each term that is dropped, added or tested or a note that several terms have been added or removed. A row contains the name of the term, the DF, the p-value and the action taken. Possible codes are:Dropped,Retained,Swapped,Unswapped,Significant,Nonsignificant,Absent,Added,RemovedandBoundary. If the changed model did not converge,Unconvergedwill be added to the code. Note that the logicalasreml.obj$convergealso reflects whether there is convergence.
A call to asrtests with test.summary = NULL re-initializes the test.summary data.frame.

Usage

asrtests(asreml.obj, wald.tab = NULL, test.summary = NULL, 
                denDF = "default", ...)

Arguments

asreml.obj
an asreml object for a fitted model.
wald.tab
a data.frame containing a pseudo-anova table for the fixed terms produced by wald.asreml; it should have 4 columns. Sometimes wald.asreml returns a data.frame and at other times
test.summary
a data.frame with columns term, DF, denDF, p and action containing the results of previous hypothesis tests.
denDF
Specifies the enthod to use in computing approximate denominator degrees of freedom when wald.asreml is called. Can be none to suppress the computations, numeric for numerical methods,
...
further arguments passed to wald.asreml.

Value

  • An object of S3-class asrtests.

See Also

asremlPlus-package, testranfix.asrtests, choose.model.asrtests, rmboundary.asrtests, sig.devn.reparam.asrtests

Examples

Run this code
data(Wheat.dat)

# Fit initial model
current.asr <- asreml(yield ~ Rep + WithinColPairs + Variety, 
                      random = ~ Row + Column + units,
                      rcov = ~ ar1(Row):ar1(Column), 
                      data=Wheat.dat)

# Load current fit into an asrtests object
current.asrt <- asrtests(current.asr, NULL, NULL)

# Check for and remove any boundary terms
current.asrt <- rmboundary.asrtests(current.asrt)

Run the code above in your browser using DataLab