• No results found

Inference: Fixed effects

In document ASREML user guide release 3.0 (Page 47-54)

Introduction

Inference for fixed effects in linear mixed models introduces some difficulties. ASReml2

In general, the methods used to construct F-tests in analysis of variance and regression cannot be used for the diversity of applications of the general linear mixed model available inASReml. One approach would be to use likelihood ratio methods (see Welham and Thompson, 1997) although their approach is not easily implemented.

Wald-type test procedures are generally favoured for conducting tests concerning

τ. The traditional Wald statistic to test the hypothesis H0 : =l for given L,r×p, and l,1, is given by

W = (ˆ−l)0{L(X0H−1X)1L0}−1(ˆ−l) (2.17)

and asymptotically, this statistic has a chi-square distribution on r degrees of freedom. These are marginal tests, so that there is an adjustment for all other terms in the fixed part of the model. It is also anti-conservative if p-values are constructed because it assumes the variance parameters are known.

The small sample behaviour of such statistics has been considered by Kenward and Roger (1997) in some detail. They presented a scaled Wald statistic, to- gether with an F-approximation to its sampling distribution which they showed performed well in a range (though limited in terms of the range of variance models available in ASReml) of settings.

In the following we describe the facilities now available inASRemlfor conducting inference concerning terms which are the in dense fixed effects model component of the general linear mixed model. These facilities are not available for any terms in the sparse model. These include facilities for computing two types of Wald F statistics and partial implementation of the Kenward and Roger adjustments. Incremental and Conditional Wald F Statistics

The basic tool for inference is the Wald statistic defined in equation 2.17. ASReml

produces a test of fixed effects, that reduces to an F statistic in special cases, by dividing the Wald statistic, constructed with l = 0, by r, the numerator degrees of freedom. In this form it is possible to perform an approximate F

test if we can deduce the denominator degrees of freedom. However, there are several ways L can be defined to construct a test for a particular model term, two of which are available inASReml. These Wald F statistics are labelledF-inc

2 Some theory 21

(for incremental) and F-con(for conditional) respectively. For balanced designs, these Wald F statistics are numerically identical to the F statistics obtained from the standard analysis of variance.

The first method for computing Wald statistics (for each term) is the so-called “incremental” form. For this method, Wald statistics are computed from an incremental sum of squares in the spirit of the approach used in classical regression analysis (see Searle, 1971). For example if we consider a very simple model with terms relating to the main effects of two qualitative factors Aand B, given symbolically by

y1+A+B

where the 1 represents the constant term (µ), then the incremental sums of squares for this model can be written as the sequence

R(1)

R(A|1) = R(1,A)−R(1)

R(B|1,A) = R(1,A,B)−R(1,A)

where the R(·) operator denotes the reduction in the total sums of squares due to a model containing its argument andR(·|·) denotes the difference between the reduction in the sums of squares for any pair of (nested) models. ThusR(B|1,A) represents the difference between the reduction in sums of squares between the so-called maximal “model”

y1+A+B

and

y1+A

Implicit in these calculations is that

we only compute Wald statistics for estimable functions (Searle, 1971, page

408),

all variance parameters are held fixed at the current REML estimates from the

maximal model

In this example, it is clear that the incremental Wald statistics may not produce thedesiredtest for the main effect ofA, as in many cases we would like to produce a Wald statistic for Abased on

2 Some theory 22

The issue is further complicated when we invoke “marginality” considerations. The issue of marginality between terms in a linear (mixed) model has been dis- cussed in much detail by Nelder (1977). In this paper Nelder defines marginality for terms in a factorial linear model with qualitative factors, but later Nelder (1994) extended this concept to functional marginality for terms involving quan- titative covariates and for mixed terms which involve an interaction between quantitative covariates and qualitative factors. Referring to our simple illustra- tive example above, with a full factorial linear model given symbolically by

y1+A+B+A.B

thenA andBare said to be marginal to A.B, and 1is marginal toAand B. In a three way factorial model given by

y1+A+B+C+A.B+A.C+B.C+A.B.C

the terms A, B, C, A.B, A.C and B.Care marginal to A.B.C. Nelder (1977, 1994) argues that meaningful and interesting tests for terms in such models can only be conducted for those tests which respect marginality relations. This philos- ophy underpins the following description of the second Wald statistic available in ASReml, the so-called “conditional” Wald statistic. This method is invoked by placing!FCON on the datafile line. ASRemlattempts to construct conditional Wald statistics for each term in the fixed dense linear model so that marginality relations are respected. As a simple example, for the three way factorial model the conditional Wald statistics would be computed as

Term Sums of Squares Mcode

1 R(1) .

A R(A|1,B,C,B.C) =R(1,A,B,C,B.C) -R(1,B,C,B.C) A

B R(B|1,A,C,A.C) =R(1,A,B,C,A.C) -R(1,A,C,A.C) A

C R(C|1,A,B,A.B) =R(1,A,B,C,A.B) -R(1,A,B,A.B) A

A.B R(A.B|1,A,B,C,A.C,B.C) =R(1,A,B,C,A.B,A.C,B.C) -R(1,A,B,C,A.C,B.C) B

A.C R(A.C|1,A,B,C,A.B,B.C) =R(1,A,B,C,A.B,A.C,B.C) -R(1,A,B,C,A.B,B.C) B

B.C R(B.C|1,A,B,C,A.B,A.C) =R(1,A,B,C,A.B,A.C,B.C) -R(1,A,B,C,A.B,A.C) B

A.B.C R(A.B.C|1,A,B,C,A.B,A.C,B.C) =R(1,A,B,C,A.B,A.C,B.C,A.B.C) -

R(1,A,B,C,A.B,A.C,B.C) C

Of these the conditional Wald statistic for the 1, B.C andA.B.C terms would be the same as the incremental Wald statistics produced using the linear model

y1+A+B+C+A.B+A.C+B.C+A.B.C

The preceeding table includes a so-calledM(marginality) code reported byASReml

when conditional Wald statistics are presented. All terms with the highestMcode letter are tested conditionally on all other terms in the model, i.e. by dropping the term from the maximum model. All terms with the preceeding Mcode letter,

2 Some theory 23

are marginal to at least one term in a higher group, and so forth. For example, in the table, model term A.B hasMcode Bbecause it is marginal to model term

A.B.C and model term A has M code A because it is marginal to A.B, A.C and

A.B.C. Model termmu (Mcode .) is a special case in that its test is conditional on all covariates but no factors. Following is someASRemloutput from the.aov

table which reports the terms in the conditional statistics.

Marginality pattern for F-con calculation -- Model terms -- Model Term DF 1 2 3 4 5 6 7 8 1 mu 1 * . . . . 2 water 1 I * C C . . c . 3 variety 7 I I * C . c . . 4 sow 2 I I I * C . . . 5 water.variety 7 I I I I * C C . 6 water.sow 2 I I I I I * C . 7 variety.sow 14 I I I I I I * . 8 water.variety.sow 14 I I I I I I I *

F-inc tests the additional variation explained when the term (*) is added to a model consisting of the I terms. F-con tests the additional variation explained when the term (*) is added to a model consisting of the I and C/cterms. Any

c terms are ignored in calculating DenDF forF-con using numericalderivatives for computational reasons. The . terms are ignored for both F-inc and F-con

tests.

Consider now a nested model which might be represented symbolically by

y1+REGION+REGION.SITE

For this model, the incremental and conditional Wald F statistics will be the same. However, it is not uncommon for this model to be presented toASRemlas

y1+REGION+SITE

withSITEidentified acrossREGIONrather than withinREGION. Then the nested structure is hidden butASRemlwill still detect the structure and produce a valid conditional Wald F statistic. This situation will be flagged in the Mcode field by changing the letter to lower case. Thus, in the nested model, the three M codes would be.,AandBbecauseREGION.SITEis obviously an interaction dependent

2 Some theory 24

on REGION. In the second model, REGION and SITE appear to be independent factors so the initial M codes are., Aand A. However they are not independent becauseREGIONremoves additional degrees of freedom fromSITE, so theMcodes are changed from.,Aand Ato.,aandA.

When using the conditional Wald F statistic, it is important to know what the “maximal conditional” model (MCM) is for that particular statistic. It is given explicitly in the .aov file. The purpose of the conditional Wald F statistic is to facilitate inference for fixed effects. It is not meant to be prescriptive of the appropriate test nor is the algorithm for determining the MCM foolproof. The Wald statistics are collectively presented in a summary table in the .asr

file. The basic table includes the numerator degrees of freedom (ν1i) and the incremental Wald F statistic for each term. To this is added the conditional Wald F statistic and the M code if !FCON is specified. A conditional Wald F statistic is not reported for mu in the .asr but is in the .aov file (adjusted for covariates).

The!FOWNqualifier (page 84) allows the user to replace any/all of the conditional ASReml3

Wald F statistics with tests of the same terms but adjusted for other model terms as specified by the user; the !FOWNtest is not performed if it implies a change in degrees of freedom from that obtained by the incremental model.

Kenward and Roger Adjustments

In moderately sized analyses, ASRemlwill also include the denominator degrees of freedom (DenDF, denoted byν2i, Kenward and Roger, 1997) and a probablity value if these can be computed. They will be for the conditional Wald F statistic if it is reported. The !DDF i (see page 69) qualifier can be used to suppress the

DenDF calculation (!DDF -1) or request a particular algorithmic method: !DDF 1 for numerical derivatives, !DDF 2 for algebraic derivatives. The value in the probability column (eitherP incorP con) is computed from an1i,ν2i reference

distribution. An approximation is used for computational convenience when cal- culating the DenDFfor Conditional F statistics using numerical derivatives. The

DenDFreported then relates to a maximal conditional incremental model (MCIM) which, depending on the model order, may not always coincide with the max- imal conditional model (MCM) under which the conditional F statistic is cal- culated. The MCIM model omits terms fitted after any terms ignored for the conditional test (Iafter . in marginality pattern). In the example above, MCIM ignores variety.sowwhen calculating DenDF for the test of waterand ignores

2 Some theory 25

available, it is often possible, though anti-conservative to use the residual degrees of freedom for the denominator.

Kenward and Roger (1997) pursued the concept of construction of Wald-type test statistics through an adjusted variance matrix of τˆ. They argued that it is useful to consider an improved estimator of the variance matrix of τˆ which has less bias and accounts for the variability in estimation of the variance parameters. There are two reasons for this. Firstly, the small sample distribution of Wald F statistics is simplified when the adjusted variance matrix is used. Secondly, if measures of precision are required for τˆ or effects therein, those obtained from the adjusted variance matrix will generally be preferred. Unfortunately the Wald statistics are currently computed using an unadjusted variance matrix.

Approximate stratum variances

ASReml reports approximate stratum variances and degrees of freedom for sim- ple variance components models. For the linear mixed-effects model with vari- ance components (setting σH2 = 1) where G = ⊕qj=1γjIbj, it is often possible

to consider a natural ordering of the variance component parameters including

σ2. Based on an idea due to Thompson (1980), ASReml computes approximate

stratum degrees of freedom and stratum variances by a modified Cholesky diag- onalisation of the average information matrix. That is, ifF is the average infor- mation matrix for σ, letU be an upper triangular matrix such that F =U0U. We define

Uc=DcU

where Dc is a diagonal matrix whose elements are given by the inverse elements of the last column of U ie dcii = 1/uir, i= 1, . . . , r. The matrix Uc is therefore upper triangular with the elements in the last column equal to one. If the vector

σ is ordered in the “natural” way, with σ2 being the last element, then we can

define the vector of so called “pseudo” stratum variance components by

ξ =Ucσ

Thence

var (ξ) =D2c

The diagonal elements can be manipulated to produce effective stratum degrees of freedom Thompson (1980) viz

νi= 2ξ2i/d2cii

3

A guided tour

Introduction

Nebraska Intrastate Nursery (NIN) field experiment

The ASReml data file

The ASReml command file

The title line Reading the data The data file line Specifying the terms in the mixed model Tabulation Prediction Variance structures

Running the job

Description of output files

The.asrfile The.slnfile The.yhtfile

Tabulation, predicted values and functions of the variance

components

3 A guided tour 27

3.1

Introduction

This chapter presents a guided tour of ASReml, from data file preparation and basic aspects of the ASRemlcommand file, to running an ASRemljob and inter- preting the output files. You are encouraged to read this chapter before moving to the later chapters;

a real data example is used in this chapter for demonstration, see below, the same data are also used in later chapters,

links to the formal discussion of topics are clearly signposted by margin notes.

This example is of a randomised block analysis of a field trial, and is only one of Revised 08

many forms of analysis that ASRemlcan perform. It is chosen because it allows an introduction to the main ideas involved in running ASReml. However some aspects of ASReml, in particular, pedigree files (see Chapter 9) and multivariate analysis (see Chapter 8) are only covered in later chapters.

ASReml is essentially a batch program with some optional interactive features. The typical sequence of operations when usingASRemlis

Prepare the data (typically using a spreadsheet or data base program) Export that data as an ASCII file (for example export it as a .csv (comma

separated values) file fromExcel)

Prepare a job file with filename extension.as. Run the job file withASReml

Review the various output files revise the job and re run it, or

extract pertinent results for your report.

You will need a file editor to create the command file and to view the various output files. On unix systems, vi and emacs are commonly used. Under Win- dows, there are several suitable program editors available such asASReml-Wand

ConTextdescribed in section 1.3. ASReml2

In document ASREML user guide release 3.0 (Page 47-54)