# Example: Estimating parameters for a normal iAR model
library(iAR)
times <- 1:100
model <- iAR(family = "norm", times = times, coef = 0.9, hessian = TRUE)
model <- sim(model) # Simulate the series
model <- loglik(model) # Estimate parameters using MLE
print(model@coef) # Access the estimated coefficients
print(model@loglik) # Access the computed log-likelihood
Run the code above in your browser using DataLab