Description Usage Arguments Value

View source: R/createCandidateMatrix.R

This function creates candidate, a matrix where the (i,j)th entry corresponds to the number of changepoints in difference series for location j that occured at time i. For example, suppose location i_1 was paired with i_2, i_3, and i_4. If the statistic for i_1-i_2 and i_1-i_4 exceeded the threshold at time j, then candidate_i,j = 2.

1 | ```
createCandidateMatrix(data, statistics, pairs, crit)
``` |

`data` |
The data.frame containing the observations, restructured as in pairwiseSNHT. So, the first column should be time, and the other columns should be named with the locations and contain the observed values at each location. |

`statistics` |
The time x (number of pairs) matrix of SNHT statistics computed for each difference series. |

`pairs` |
The list object whose ith element specifies the neighboring locations to the ith location. |

`crit` |
The critical value such that if the snht statistic is larger than crit, a changepoint is assumed to have occured. Defaults to 100, as recommended in Haimberger (see references). |

A matrix of dimension time x (number of locations). The (i,j) element of this matrix indicates the number of changepoints found in difference series containing the jth location at time i.

snht documentation built on Nov. 17, 2017, 4:45 a.m.

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.