[R] Help with order.max in ar.yw.default

debra ragland ragland.debra at yahoo.com
Wed Jul 1 14:50:21 CEST 2015


Hello, 

I am trying to fit my data to the default autoregressive models in R. I'm trying to apply the effectiveSize function from the coda package to a list of data frames using; 

sapply(splits, function(x) coda::effectiveSize(x["V5"])) 

However when I do, I get the error; 
Error in ar.yw.default(x, aic = aic, order.max = order.max, na.action = na.action,  : 
  'order.max' must be >= 1 

For some reason the command above works fine if my list is smaller (otherwise, not properly split). And it works perfectly fine on one of my data sets. If I apply it to anything else (data of a similar set up) I get the error. I've tried looking for solutions on the internet but so far I've come up with nothing. 

Has this happened to anyone before? Can I bypass this order. max call? 

	[[alternative HTML version deleted]]



More information about the R-help mailing list