On 07/11/2012 18:18, Arnaud Mosnier wrote:
> Alain, thank for your answer. I will try with different starting values.
> However, in order to provide a reasonable value, is there in R a 
> method to test the temporal autocorrelation similarly as the function 
> variogram (gstat) or equivalent that can be used to test spatial 
> autocorrelation ?
> I know the acf function but it supposes a regular time step ...

Arnaud...you can apply the variogram on time series. See Chapter 6 in 
our 2012 book for an example and R code.

Alain
>
> Arnaud
>
>     Message: 1
>     Date: Wed, 07 Nov 2012 16:33:29 +0200
>     From: Highland Statistics Ltd <highstat@highstat.com
>     <mailto:highstat@highstat.com>>
>     To: r-sig-mixed-models@r-project.org
>     <mailto:r-sig-mixed-models@r-project.org>
>     Subject: Re: [R-sig-ME] corARMA in lme (Arnaud Mosnier)
>     Message-ID: <509A7139.9070508@highstat.com
>     <mailto:509A7139.9070508@highstat.com>>
>     Content-Type: text/plain; charset=ISO-8859-1; format=flowed
>
>     On 07/11/2012 13:00, r-sig-mixed-models-request@r-project.org
>     <mailto:r-sig-mixed-models-request@r-project.org> wrote:
>     > Send R-sig-mixed-models mailing list submissions to
>     > r-sig-mixed-models@r-project.org
>     <mailto:r-sig-mixed-models@r-project.org>
>     >
>     > To subscribe or unsubscribe via the World Wide Web, visit
>     > https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models
>     > or, via email, send a message with subject or body 'help' to
>     > r-sig-mixed-models-request@r-project.org
>     <mailto:r-sig-mixed-models-request@r-project.org>
>     >
>     > You can reach the person managing the list at
>     > r-sig-mixed-models-owner@r-project.org
>     <mailto:r-sig-mixed-models-owner@r-project.org>
>     >
>     > When replying, please edit your Subject line so it is more specific
>     > than "Re: Contents of R-sig-mixed-models digest..."
>     >
>     >
>     > Today's Topics:
>     >
>     >     1. corARMA in lme (Arnaud Mosnier)
>     >     2. Re: lmer: effects of forcing fixed intercepts and slopes
>     >        (Gjalt-Jorn Peters)
>     >     3. Re: lmer: effects of forcing fixed intercepts and slopes
>     >        (ONKELINX, Thierry)
>     >
>     >
>     >
>     ----------------------------------------------------------------------
>     >
>     > Message: 1
>     > Date: Tue, 6 Nov 2012 12:59:19 -0500
>     > From: Arnaud Mosnier <a.mosnier@gmail.com
>     <mailto:a.mosnier@gmail.com>>
>     > To: "r-sig-mixed-models@r-project.org
>     <mailto:r-sig-mixed-models@r-project.org>"
>     >       <r-sig-mixed-models@r-project.org
>     <mailto:r-sig-mixed-models@r-project.org>>
>     > Subject: [R-sig-ME] corARMA in lme
>     > Message-ID:
>     >      
>     <CANkFkEd3ph3pLw-yUpRXCk3U=GMsgFqR-Qneh5BF8Xx4m1dFHg@mail.gmail.com <mailto:GMsgFqR-Qneh5BF8Xx4m1dFHg@mail.gmail.com>>
>     > Content-Type: text/plain
>     >
>     > Dear mixed-models useRs,
>     >
>     > I made a mixed model of the form
>     >
>     > lme(Distance ~ season, random = ~1|yearTagged/tag, correlation =
>     > corAR1(form= ~Time|yearTagged/tag), data = dat)
>     >
>     > or
>     >
>     > lme(Distance ~ season, random = ~1|yearTagged/tag, correlation =
>     > corARMA(form= ~Time|yearTagged/tag, p=1, q=1), data = dat)
>     >
>     > In the AR1 model, the Phi value obtained for the corAR1
>     structure is 0.
>     > In the ARMA(1,1) model, both Phi1 and Theta1 are equal to 0.
>     >
>     > I find this strange. I believed first that it was caused by the
>     fact that
>     > yearTagegd and tag variables were not considered as factor, but
>     it did not
>     > change anything if I convert them to factor.
>     > The temporal autocorrelation is not obvious in the residuals of
>     the model
>     > without a temporal structure included (i.e. without corAR1 or
>     corARMA), but
>     > can I conclude that there is not correlation based on Phi value ?
>
>     Arnaud...no you cannot conclude that. The random effect structure is
>     already imposing a correlation on the data from the same tag, and also
>     on data from the same yearTagged. Phi alone does not quantify your
>     correlation. The ARMA is trying to add extra correlation. On top of
>     that..the AR and ARMA correlation structures are quite specific.
>
>     If you think that there should be correlation, try different starting
>     values for the phi.
>
>     Alain
>
>
>     > Thanks for your help,
>     >
>     > Arnaud
>     >
>     >       [[alternative HTML version deleted]]
>     >
>     >
>
>
>
>
>
>     --
>
>     Dr. Alain F. Zuur
>     First author of:
>
>     1. Analysing Ecological Data (2007).
>     Zuur, AF, Ieno, EN and Smith, GM. Springer. 680 p.
>     URL: www.springer.com/0-387-45967-7
>     <http://www.springer.com/0-387-45967-7>
>
>
>     2. Mixed effects models and extensions in ecology with R. (2009).
>     Zuur, AF, Ieno, EN, Walker, N, Saveliev, AA, and Smith, GM. Springer.
>     http://www.springer.com/life+sci/ecology/book/978-0-387-87457-9
>
>
>     3. A Beginner's Guide to R (2009).
>     Zuur, AF, Ieno, EN, Meesters, EHWG. Springer
>     http://www.springer.com/statistics/computational/book/978-0-387-93836-3
>
>
>     4. Zero Inflated Models and Generalized Linear Mixed Models with
>     R. (2012) Zuur, Saveliev, Ieno.
>     http://www.highstat.com/book4.htm
>
>     Other books: http://www.highstat.com/books.htm
>
>
>     Statistical consultancy, courses, data analysis and software
>     Highland Statistics Ltd.
>     6 Laverock road
>     UK - AB41 6FN Newburgh
>     Tel: 0044 1358 788177
>     Email: highstat@highstat.com <mailto:highstat@highstat.com>
>     URL: www.highstat.com <http://www.highstat.com>
>     URL: www.brodgar.com <http://www.brodgar.com>
>
>
>
>


-- 

Dr. Alain F. Zuur
First author of:

1. Analysing Ecological Data (2007).
Zuur, AF, Ieno, EN and Smith, GM. Springer. 680 p.
URL: www.springer.com/0-387-45967-7


2. Mixed effects models and extensions in ecology with R. (2009).
Zuur, AF, Ieno, EN, Walker, N, Saveliev, AA, and Smith, GM. Springer.
http://www.springer.com/life+sci/ecology/book/978-0-387-87457-9


3. A Beginner's Guide to R (2009).
Zuur, AF, Ieno, EN, Meesters, EHWG. Springer
http://www.springer.com/statistics/computational/book/978-0-387-93836-3


4. Zero Inflated Models and Generalized Linear Mixed Models with R. (2012) Zuur, Saveliev, Ieno.
http://www.highstat.com/book4.htm

Other books: http://www.highstat.com/books.htm


Statistical consultancy, courses, data analysis and software
Highland Statistics Ltd.
6 Laverock road
UK - AB41 6FN Newburgh
Tel: 0044 1358 788177
Email: highstat@highstat.com
URL: www.highstat.com
URL: www.brodgar.com


	[[alternative HTML version deleted]]

