dLagM (version 1.0.19)

rolCorPlot: PLot the rolling correlations

Description

Plots the rolling correlations along with other required statistics to visualise the approach of Gershunov et al. (2001) to test the significance of signal from rolling correlation analysis.

Usage

rolCorPlot(x , y , width, start = 1, level = 0.95, main = NULL, 
           SDtest = TRUE, N = 500)

Arguments

x

A numeric vector.

y

A numeric vector.

width

A numeric vector of window lengths of the rolling correlation analysis.

start

The time of the first observation

level

Confidence level for intervals.

main

The main title of the plot.

SDtest

Set to TRUE to run test the significance of signal from rolling correlation analysis along with plotting.

N

An integer showing the number of series to be generated in Monte Carlo simulation.

Value

rolCor

A matrix showing rolling correlations for each width on its columns.

rolcCor.avr.filtered

A vector showing average rolling correlations filtered by running median nonlinear filter against outliers.

rolcCor.avr.raw

A vector showing unfiltered average rolling correlations.

rolCor.sd

A vector showing standard deviations of rolling correlations for each width.

rawCor

Pearson correlation between two series.

sdPercentiles

Percentiles of MC distribution of standard deviations of rolling correlations as the test limits.

test

A data frame showing the standard deviations of rolling correlations for each width along with level and (1-level) limits.

References

Gershunov, A., Scheider, N., Barnett, T. (2001). Low-Frequency Modulation of the ENSO-Indian Monsoon Rainfall Relationship: Signal or Noise? Journal of Climate, 14, 2486 - 2492.

Examples

Run this code
# NOT RUN {
data(wheat)
rolCorPlot(x = wheat[,2], y = wheat[,5] , start = 1960, width = c(7, 11, 15), level = 0.95, N = 100)
# }

Run the code above in your browser using DataLab