Description Usage Arguments Value Author(s) References Examples
Create two time series with specific autocorrelation γ, cross-correlation
ρ, mean ts.mean
, and standard deviation ts.sd
using the
phase partnered algorithm described by Vasseur (2007)
1 |
n |
number of time steps in time series. Default is |
rho |
cross-correlation between the two time series (-1≤ ρ ≤ 1).
Default is |
gamma |
autocorrelation of each time series. Gamma (γ) describes the relationship between
frequency f and power P: P(f)=1/f^γ. If -2≤ γ ≤ 0: blue noise and 0≤ γ ≤ 2: red noise. Default is |
sigma |
standard deviation of both time series. Default is |
mu |
mean of both time series. Default is |
Returns a named list containing the following:
rho |
Cross-correlation of the time series |
gamma |
Autocorrelation of the time series |
sigma |
Standard deviation of the time series |
mu |
Mean of the time series |
timeseries |
|
Tarik C. Gouhier (tarik.gouhier@gmail.com)
Gouhier, T. C., F. Guichard, and A. Gonzalez. 2010. Synchrony and stability of food webs in metacommunities. The American Naturalist 175:E16-E34.
Vasseur, D. A. 2007. Environmental colour intensifies the Moran effect when population dynamics are spatially heterogeneous. Oikos 116:1726-1736.
1 2 3 4 5 6 7 | # Positively cross-correlated white noise
pos.corr=phase.partnered(n = 100, rho = 0.7, gamma = 0)
# Negatively cross-correlated white noise
neg.corr=phase.partnered(n = 100, rho = -1, gamma = 0)
par(mfrow=c(2,1))
matplot (pos.corr$timeseries, t="l", lty=1)
matplot (neg.corr$timeseries, t="l", lty=1)
|
synchrony 0.2.3 loaded.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.