Dear R-list members, Cynthia M. Jones wrote a paper (Fitting growth curves to retrospective size-at-age data, Fisheries Research 46(2000):123-129; abstract at http://www.elsevier.nl/gej-ng/10/19/44/70/24/37/abstract.html)where the SAS procedure MIXED, Macro NLINMIX (Littell et. al., 1996)was used to estimate the von Bertalanffy growth function parameters assuming that data from the same fish are repeated-measures with autoregressive correlation structure and fitting with a nonlinear repeated-measures model. Is there any similar procedure that I can use in R? Thanks, Antonio Olinto -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
Antonio Olinto <aolinto at bignet.com.br> writes:> Cynthia M. Jones wrote a paper (Fitting growth curves to retrospective > size-at-age data, Fisheries Research 46(2000):123-129; abstract at > http://www.elsevier.nl/gej-ng/10/19/44/70/24/37/abstract.html)where the > SAS procedure MIXED, Macro NLINMIX (Littell et. al., 1996)was used to > estimate the von Bertalanffy growth function parameters assuming that > data from the same fish are repeated-measures with autoregressive > correlation structure and fitting with a nonlinear repeated-measures > model. > > Is there any similar procedure that I can use in R?Yes - the nlme function from the library of the same name. The usage of both lme and nlme is described in @Book{pinh:bate:2000, author = {Jos\'{e} C. Pinheiro and Douglas M. Bates}, title = {Mixed-Effects Models in \textsf{S} and \textsf{S-PLUS}}, publisher = {Springer}, year = 2000, series = {Statistics and Computing} } -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
Antonio -- You can estimate a linear mixed model with lme in library(nlme). Models typically take a long time to estimate compared to sas proc mixed (but I had a few thousand observations). The nonlinear mixed models can be done using nlme in library(nlme). However, I'm not clear on how to set up the functions. If someone has a complete example (with function), I'd like to see it. Note that SAS now has proc NLMixed (not a macro). Cheers, Dan =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-Dan Powers Associate Professor, Sociology University of Texas at Austin On Wed, 28 Mar 2001, Antonio Olinto wrote:> Dear R-list members, > > Cynthia M. Jones wrote a paper (Fitting growth curves to retrospective > size-at-age data, Fisheries Research 46(2000):123-129; abstract at > http://www.elsevier.nl/gej-ng/10/19/44/70/24/37/abstract.html)where the > SAS procedure MIXED, Macro NLINMIX (Littell et. al., 1996)was used to > estimate the von Bertalanffy growth function parameters assuming that > data from the same fish are repeated-measures with autoregressive > correlation structure and fitting with a nonlinear repeated-measures > model. > > Is there any similar procedure that I can use in R? > > Thanks, > > Antonio Olinto > -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- > r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html > Send "info", "help", or "[un]subscribe" > (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch > _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._ >-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
> > Dear R-list members, > > Cynthia M. Jones wrote a paper (Fitting growth curves to retrospective > size-at-age data, Fisheries Research 46(2000):123-129; abstract at > http://www.elsevier.nl/gej-ng/10/19/44/70/24/37/abstract.html)where the > SAS procedure MIXED, Macro NLINMIX (Littell et. al., 1996)was used to > estimate the von Bertalanffy growth function parameters assuming that > data from the same fish are repeated-measures with autoregressive > correlation structure and fitting with a nonlinear repeated-measures > model. > > Is there any similar procedure that I can use in R?elliptic in my growth library will do this even if the times are unequally spaced. (Unless it changed recently, nlme gives incorrect answers for the AR in this case.) Jim> > Thanks, > > Antonio Olinto > -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- > r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html > Send "info", "help", or "[un]subscribe" > (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch > _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._ >-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
>> >> Dear R-list members, >> >> Cynthia M. Jones wrote a paper (Fitting growth curves to retrospective >> size-at-age data, Fisheries Research 46(2000):123-129; abstract at >> http://www.elsevier.nl/gej-ng/10/19/44/70/24/37/abstract.html)where the >> SAS procedure MIXED, Macro NLINMIX (Littell et. al., 1996)was used to >> estimate the von Bertalanffy growth function parameters assuming that >> data from the same fish are repeated-measures with autoregressive >> correlation structure and fitting with a nonlinear repeated-measures >> model. >> >> Is there any similar procedure that I can use in R? > > elliptic in my growth library will do this even if the times are > unequally spaced. (Unless it changed recently, nlme gives incorrect > answers for the AR in this case.)There is a continuous AR(1) class, corCAR1, in the nlme library which should be used in the case when the times are unequally spaced and measured on a continuous scale. This is equivalent to the correlation structure implemented in elliptic. There are other correlation classes in nlme that can be used with continuous, unequallly spaced times, such as the spatial correlation structures. In the case of a "classical" AR(1) model, because the autocorrelation parameter is allowed to take negative values (unlike in the continuous AR(1) case, where it is restricted to be non-negative), the times need to be integer valued (as stated in the help page for corAR1, the correlation class for AR(1) in nlme). Note that, even in this case, the times are not required to be equally spaced. Regards, --Jose' ----------------------------------------------------------------------------- Jose' Pinheiro Bell Laboratories jcp at research.bell-labs.com 600 Mountain Avenue, Room 2C-258 office: (908) 582-2390 Murray Hill, NJ 07974 fax: (908) 582-3340 ----------------------------------------------------------------------------- -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._