Error in apply(x2, 1, diff) : dim(X) must have a positive length
Yes, I just checked out the bootstrap package: the problem is that it passes vectors (not matrices) to your function and thats why you get the error you do. Just use diff() instead of apply(,, diff) in your function and you'll be fine. Michael
On Mon, Feb 13, 2012 at 12:48 PM, hithit168 <ccchristy at live.com> wrote:
Thanks. I use the bootstrap() function from the bootstrap package. Let me try it again to see if I get any luck :) -- View this message in context: http://r.789695.n4.nabble.com/Error-in-apply-x2-1-diff-dim-X-must-have-a-positive-length-tp4382435p4384608.html Sent from the R help mailing list archive at Nabble.com.
______________________________________________ R-help at r-project.org mailing list 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.