[R] coherency and phase plots

stephen sefick ssefick at gmail.com
Tue Jan 29 20:09:14 CET 2008


spec.pgram does accept multivariate time series, and I have used this
with success.  I just don't know if there is an implementation of
cross-spectrum in R.  Or what exactley Phase vs frequency is telling
me.

On Jan 29, 2008 2:06 PM, Donald McKenzie <dmck at u.washington.edu> wrote:
> See the help for spec.pgram().  It accepts a multivariate time series
> as an argument.
>
>
> Don McKenzie, Research Ecologist
> Fire and Environmental Research Applications (FERA)
> Pacific Wildland Fire Sciences Lab, USDA Forest Service
>
> Affiliate Assistant Professor
> College of Forest Resources
> JISAO / CSES Climate Impacts Group
> University of Washington
>
> donaldmckenzie at fs.fed.us
> dmck at u.washington.edu
> (206)732-7824;   fax (206)732-7801
>
>
> On Tue, 29 Jan 2008, stephen sefick wrote:
>
> > I am having a hard time interpreting the phase and coherency plots.
> > x is two timeseries that occur at the same time   i.e.
> >
> >          a       b
> > 1       11.2   12.3
> > 16     11.3   12.4
> > 31     11.4   12.5
> > 46     11.5   12.6
> > ...etc
> >
> > even though my example is does not show this they are oscillating at
> > more or less the same frequency just shifted by t=x (imagine two sine
> > waves offset with the 2nd sine wave starting at the peak of the
> > first).  I would like to know what x is.  I think I am looking for the
> > phase shift?  The coherency?  Cross-spectrum?  And I have read the
> > help files,  Shumway and Stoffer has a small section on this, I don't
> > have journal access,  and I am having trouble finding anything on the
> > internet.
> >
> > s = spec.pgram(x)
> > par(mfrow = c(2,1))
> > plot(s, plot.type = "coh")
> > plot(s, plot.type = "pha")
> >
> > Can R do the cross-spectrum of two timeseries?  How?
> >
> >
> > --
> > Let's not spend our time and resources thinking about things that are
> > so little or so large that all they really do for us is puff us up and
> > make us feel like gods.  We are mammals, and have not exhausted the
> > annoying little problems of being mammals.
> >
> >                                                               -K. Mullis
> >
> > ______________________________________________
> > R-help at r-project.org mailing list
> > https://stat.ethz.ch/mailman/listinfo/r-help
> > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> > and provide commented, minimal, self-contained, reproducible code.
> >
>
>
>



-- 
Let's not spend our time and resources thinking about things that are
so little or so large that all they really do for us is puff us up and
make us feel like gods.  We are mammals, and have not exhausted the
annoying little problems of being mammals.

								-K. Mullis



More information about the R-help mailing list