> What in the world am I missing??

stype.  As in (from help(boot)

   stype: A character string indicating what the second argument of
          statistic represents. Possible values of stype are '"i"'
          (indices - the default), '"f"' (frequencies), or '"w"'
          (weights).

This works.  n.b. the second argument.

mean.b <- function(x,ind,...) {
  mean(x[ind])
}

zz <- rnorm(20)
mean(zz)
res <- boot(zz,mean.b,R=5)

I'm sure there's a cleaner way to do that, but I don't know it (yet).

Cheers

Jason

______________________________________________
[EMAIL PROTECTED] mailing list
https://www.stat.math.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html

Reply via email to