Performs bootstrap statistical tests to validate MSAR models. Marginal distribution, auto correlation function and up-crossings are considered. For each of them the tests statistic computed from observations is compared to the distribution of the satistics corresponding to the MSAR model.

1 | ```
test.model.MSAR(data,simu,lag=NULL,id=1,u=NULL)
``` |

`data` |
observed (or reference) time series, array of dimension T*N.samples*d |

`simu` |
simulated time series, array of dimension T*N.sim*d. N.sim have to be K*N.samples with K large enough (for instance, K=100) |

`lag` |
maximum lag for auto-correlation functions. |

`id` |
considered component. It is usefull when data is multivariate. |

`u` |
considered levels for up crossings |

Test statistics Marginal distribution:

* S = \int_{-∞}^{∞} ≤ft| F_n(x)-F(x) \right| dx*

Marginal distribution, based on Anderson Darling statistic:

* S = \int_{-∞}^{∞} ≤ft| \frac{F_n(x)-F(x)}{F(x)(1-F(x))} \right| dx*

Correlation function:

* S = \int_0^L≤ft|C_n(l)-C(l)\right|dl*

Number of up crossings:

* S = \int_{-∞}^{∞}≤ft|E_n(N_u)-E(N_u)\right|du*

Returns a list including

`StaDist` |
statistics of marginal distributions, based on Smirnov like statistics |

`..$dd` |
test statistic |

`..$q.dd` |
quantiles .05 and .95 of the distribution of the test statistic under the null hypothesis |

`..$p.value` |
p value |

`Cor` |
statistics of correlation functions |

`..$dd` |
test statistic |

`..$q.dd` |
quantiles .05 and .95 of the distribution of the test statistic under the null hypothesis |

`..$p.value` |
p value |

`ENu` |
statistics of intensity of up crossings |

`..$dd` |
test statistic |

`..$q.dd` |
quantiles .05 and .95 of the distribution of the test statistic under the null hypothesis |

`..$p.value` |
p value |

`AD` |
statistics of marginal distributions, based on Anderson Darling statistics |

`..$dd` |
test statistic |

`..$q.dd` |
quantiles .05 and .95 of the distribution of the test statistic under the null hypothesis |

`..$p.value` |
p value |

Valerie Monbet, valerie.monbet@univ-rennes1.fr

valid_all, test.model.MSAR

Questions? Problems? Suggestions? Tweet to @rdrrHQ or email at ian@mutexlabs.com.

All documentation is copyright its authors; we didn't write any of that.