Dear All, I am trying to use this package ---> https://cran.r-project.org/web/packages/MARSS/index.html I am reading this book which shows some examples based on the above package ---> https://nwfsc-timeseries.github.io/atsa-labs/
In a few words, the incantation MARSS(...) estimates the parameters and MARSSparamCIs should return the confidence intervals. My problem is that MARSSparamCIs returns this error :- > MARSSparamCIs(fit) Error in MARSSharveyobsFI(MLEobj) : replacement has length zero > ### This page and the next page, explains the jargon used : https://nwfsc-timeseries.github.io/atsa-labs/sec-dlm-example-of-a-univariate-dlm.html ### Here is a MWE to recreate the error :- # This is a Time Varying Parameters regression # Here a is fixed and b is doing a RW. x1 <- rnorm(1000) b <- cumsum(rnorm(1000, sd = sqrt(.6))) y <- 1 + b*x1 + rnorm(1000) Z = array(NA,c(1,2,1000)) Z[1,1,] = rep(1,1000) Z[1,2,] = x1 mod2.list = list ( B = matrix(c(1,0,0,1),nrow = 2 , byrow = T), U = matrix(0,2,1), Q = matrix(list(0,0,0,"s2b"),2,2), Z= Z, A = matrix(0), R = matrix("r")) fit = MARSS(as.vector(y), model = mod2.list,inits = list(x0=matrix(0,nrow=2,ncol=1))) MARSSparamsCIs(fit) # The above will give this error : Error in MARSSharveyobsFI(MLEobj) : replacement has length zero Best Regards, Ashim [[alternative HTML version deleted]] ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.