jacobian.net {DChaos} | R Documentation |
Computes the partial derivatives from the best-fitted neural net model
Description
This function computes analytically the partial derivatives from the best-fitted neural net model.
Usage
jacobian.net(
model,
data,
m = 1:4,
lag = 1:1,
timelapse = c("FIXED", "VARIABLE"),
h = 2:10,
w0maxit = 100,
wtsmaxit = 1e+06,
pre.white = TRUE,
trace = 1,
seed.t = TRUE,
seed = 56666459
)
Arguments
model |
a neural network model fitted using the |
data |
a |
m |
a non-negative integer denoting a lower and upper bound for the embedding dimension (Default 1:4). |
lag |
a non-negative integer denoting a lower and upper bound for the the reconstruction delay (Default 1:1). |
timelapse |
a character denoting if the time-series data are sampled at uniform time-frequency e.g., 1-month, 1-day, 1-hour, 30-min, 5-min, 1-min and so on |
h |
a non-negative integer denoting a lower and upper bound for the number of neurones (or nodes) in the single hidden layer (Default 2:10). |
w0maxit |
a non-negative integer denoting the maximum iterations to estimate the initial parameter vector of the neural net models (Default 100). |
wtsmaxit |
a non-negative integer denoting the maximum iterations to estimate the weights parameter vector of the neural net models (Default 1e6). |
pre.white |
a logical value denoting if the user wants to use as points to evaluate the partial derivatives the delayed vectors filtered by the neural net model chosen |
trace |
a binary value denoting if the user wants to print the output on the console |
seed.t |
a logical value denoting if the user wants to fix the seed |
seed |
a non-negative integer denoting the value of the seed selected if |
Value
This function returns several objects considering the parameter set selected by the user. Partial derivatives are calculated analytically from the best-fitted neural net model. It also contains some useful information about the best-fitted feed-forward single hidden layer neural net model saved, the best set of weights found, the fitted values, the residuals obtained or the best embedding parameters set chosen. This function allows the R user uses the data previously obtained from the best-fitted neural network estimated by the netfit
function if model
is not empty. Otherwise data
has to be specified.
Note
The main reason for using neural network models is not to look for the best predictive model but to estimate a model that captures the non-linear time dependence well enough and, additionally, allows us to obtain in an analytical way (instead of numerical) the jacobian functional of the unknown underlying generator system. The estimation of this jacobian or partial derivatives will later allow us to contrast our hypothesis of chaos estimating the Lyapunov exponents.
Author(s)
Julio E. Sandubete, Lorenzo Escot
References
Eckmann, J.P., Ruelle, D. 1985 Ergodic theory of chaos and strange attractors. Rev Mod Phys 57:617–656.
Gencay, R., Dechert, W.D. 1992 An algorithm for the n lyapunov exponents of an n-dimensional unknown dynamical system. Physica D 59(1):142–157.
Shintani, M., Linton, O. 2004 Nonparametric neural network estimation of Lyapunov exponents and a direct test for chaos. Journal of Econometrics 120(1):1-33.
Examples
## set.seed(34)
## Simulates time-series data from the Logistic map with chaos
## ts <- DChaos::logistic.sim(n=1000, a=4)
## show(head(ts, 5))
## Computes analytically the partial derivatives from the best-fitted neural net model
## showed in the netfit example
## model <- DChaos::netfit(ts, m=1:4, lag=1:3, timelapse="FIXED", h=2:10)
## jacobian <- DChaos::jacobian.net(model=model)
## summary(jacobian)
## Partial derivatives are calculated analytically without setting previously any neural net model
## jacobian <- DChaos::jacobian.net(data=ts, m=3:3, lag=1:1, timelapse="FIXED", h=2:10)
## summary(jacobian)