[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

*To*: asreml@chiswick.anprod.csiro.au*Subject*: Random regression with missing values*From*: "Anne Winkelman" <awinkelman@lic.co.nz>*Date*: Wed, 13 Sep 2000 13:23:10 +1200*Sender*: asreml-owner@lamb.chiswick.anprod.csiro.au

Hi, I am attempting to use asreml to fit a random regression model using Legendre polynomials. At this point, I am simply using a small test example to make sure that the command file is correct. The example I have chosen is taken from Larry Schaeffer's course notes on rrms. The trait is body weight in gilts, with days on test (dot) as the "age" variable with levels 10, 20, 30, 40, 50, and 100. I have added a permanent environmental effect. For simplicity, relationships are not considered. I have two versions of asreml commmand files (shown below). I included the !MAXIT 1 and !S2==1 options so I can compare solutions (and standard errors) with those obtained from dfreml (or, more specifically, dxmrr) and a program written in IML (SAS). Asreml, dfreml and iml produce the same results. These programs are fine as long as there are no missing values. When missing values occur, one can use version 2 of the command file if 1) !f mv is included in the model line, and 2) the missing record is included in the data file using (in a .csv file) consecutive commas for the missing weight record. Minor question: I am unable to get version 1 to work with the same strategy. Can version 1 be used for data with missing values? Major question: Inclusion of the missing values as was done in this example for version 2 is o.k when the data set is small and the "age" variable (dot) has a small number of levels with one error variance associated with each level. For test day records in dairy cattle we may want to use days in milk (say from 1 to 270) as the age variable, where each cow has only a handful of tests. In this case, records associated with dim 1 to 45 might have one error variance assigned to them , records associated with dim 2 to 90 would have another error variance associated with them, etc. How can this error structure be specified in the asreml command file? Thanks in advance, Anne Winkelman Livestock Improvement Hamilton New Zealand The two command files are as follows: Version 1 rrprogram1.as Random regression: Legendre polynomials gilt 3 dot !I phi 6 !F perm 3 weight rrdata1.csv !SKIP 1 !CSV !MAXIT 1 #sorted by gilt, dot weight ~ mu !r gilt.phi perm.phi 1 2 2 # R header line <sites> <dimensions> <G-structures> gilt 0 0 # R structure, outer dimension dot 0 DIAG !S2==1 !+6 # R structure, inner dimension 6.25 33.75 38.00 50.00 62.50 375.00 gilt.phi 2 # G header line <model_term> <dimensions> gilt 0 0 # Outer dimension 6 0 US !CON !+21 # <order> 0 (sortc) <model> <init parm> <!qualifier> 2.5 # v11 4.9 13.5 # c21 v22 4.6 12.1 15.2 # c31 c32 v33 4.6 12.3 14.5 20.0 # c41 c42 c43 v44 4.3 11.9 14.6 19.0 25.0 # c51 c52 c53 c54 v55 1.9 6.7 9.5 10.9 15.3 150.0 # c61 c62 c63 c64 c65 v66 perm.phi 2 # perm environment header line <model_term> <dimensions> perm 0 I # Outer dimension 6 0 US !CON !+21 # <order> 0 (sortc) <model> <init parm> <!qualifier> 1.0 # v11 0.5 1.0 # c21 v22 0.5 0.5 1.0 # c31 c32 v33 0.5 0.5 0.5 1.0 # c41 c42 c43 v44 0.5 0.5 0.5 0.5 1.0 # c51 c52 c53 c54 v55 0.5 0.5 0.5 0.5 0.5 1.0 # c61 c62 c63 c64 c65 v66 Version 2 rrprogram2.as Random regression: Legendre polynomials gilt 3 dot !I phi 6 !F perm 3 weight rrdata2.csv !SKIP 1 !CSV !MAXIT 1 #sorted by dot, gilt weight ~ mu !r gilt.phi perm.phi 6 1 2 # R header line <sites> <dimensions> <G-structures> gilt 0 I !s2=6.25 # R str <levels> <0 if sorted> <structure> gilt 0 I !s2=33.75 gilt 0 I !s2=38.00 gilt 0 I !s2=50.00 gilt 0 I !s2=62.50 gilt 0 I !s2=375.00 gilt.phi 2 # G header line <model_term> <dimensions> gilt 0 0 # Outer dimension 6 0 US !CON !+21 # <order> 0 (sortc) <model> <init parm> <!qualifier> 2.5 # v11 4.9 13.5 # c21 v22 4.6 12.1 15.2 # c31 c32 v33 4.6 12.3 14.5 20.0 # c41 c42 c43 v44 4.3 11.9 14.6 19.0 25.0 # c51 c52 c53 c54 v55 1.9 6.7 9.5 10.9 15.3 150.0 # c61 c62 c63 c64 c65 v66 perm.phi 2 # perm environment header line <model_term> <dimensions> perm 0 I # Outer dimension 6 0 US !CON !+21 # <order> 0 (sortc) <model> <init parm> <!qualifier> 1.0 # v11 0.5 1.0 # c21 v22 0.5 0.5 1.0 # c31 c32 v33 0.5 0.5 0.5 1.0 # c41 c42 c43 v44 0.5 0.5 0.5 0.5 1.0 # c51 c52 c53 c54 v55 0.5 0.5 0.5 0.5 0.5 1.0 # c61 c62 c63 c64 c65 v66 ___________________________________________________________________________ THE FOLLOWING WARNINGS ATTACH TO THIS COMMUNICATION This material is intended for the named recipient only and has been created solely for the purpose and function of Livestock Improvement Corporation Limited and may contain information that is subject to the Privacy Act / Confidentiality / Privilege / Copyright. Any person other than the named recipient is prohibited from retaining / disclosing / copying / distributing / using all or part of this material. -- Asreml mailinglist archive: http://www.chiswick.anprod.csiro.au/lists/asreml

- Prev by Date:
**No subject given** - Next by Date:
**Re: Random regression with missing values** - Prev by thread:
**No subject given** - Next by thread:
**Re: Random regression with missing values** - Index(es):