# NNS.ARMA.optim: NNS ARMA Optimizer In NNS: Nonlinear Nonparametric Statistics

## Description

Wrapper function for optimizing any combination of a given `seasonal.factor` vector in NNS.ARMA. Minimum sum of squared errors (forecast-actual) is used to determine optimum across all NNS.ARMA methods.

## Usage

 ```1 2``` ```NNS.ARMA.optim(variable, training.set, seasonal.factor, method = "seq", negative.values = FALSE) ```

## Arguments

 `variable` a numeric vector. `training.set` numeric; `NULL` (defualt) Sets the number of variable observations `seasonal.factor` integers; Multiple frequency integers considered for NNS.ARMA model, i.e. `(seasonal.factor = c(12, 24, 36))` `method` options: ("comb", "seq"); `"comb"` Tries all combinations of `"seasonal.factor"` provided, while `"seq"` (default) tests each by adding element to previous iteration of `"seasonal.factor"`. `negative.values` logical; `FALSE` (default) If the variable can be negative, set to `(negative.values = TRUE)`.

## Value

Returns a list containing a vector of optimal seasonal periods `\$period`, the minimum SSE value `\$SSE`, and the `\$method` identifying which NNS.ARMA method was used.

## Note

The number of combinations will grow prohibitively large, they should be kept to a minimum when `(method = "comb")`.

`seasonal.factor` containing an element too large will result in an error. Please reduce the maximum `seasonal.factor`.

## Author(s)

Fred Viole, OVVO Financial Systems

## References

Viole, F. and Nawrocki, D. (2013) "Nonlinear Nonparametric Statistics: Using Partial Moments" http://amzn.com/1490523995

## Examples

 ``` 1 2 3 4 5 6 7 8 9 10 11 12``` ```## Nonlinear NNS.ARMA period optimization using 5 yearly lags on AirPassengers monthly data ## Not run: nns.optims <- NNS.ARMA.optim(AirPassengers, training.set = 132, seasonal.factor = seq(12, 60, 12)) ## End(Not run) ## Then use optimal parameters in NNS.ARMA ## Not run: NNS.ARMA(AirPassengers, training.set=132, seasonal.factor = nns.optims\$periods, method = nns.optims\$method) ## End(Not run) ```

NNS documentation built on April 15, 2019, 5:05 p.m.