[R] boot error: Error in statistic(data, original, ...) : unused argument(s) ( ...)

From: John Sorkin <jsorkin_at_grecc.umaryland.edu>
Date: Sat 13 Aug 2005 - 13:19:24 EST


I am having difficulty setting up a boot strap. My code is listed below. I am getting the following error message:
Error in statistic(data, original, ...) : unused argument(s) ( ...)

I neither understand the error I have made that leads to the error message, nor do I know how to fix my error. Any help would be appreciated.
Thank you,
John

R2.1.1 patched
Win 2k.

> AdjForBase2<-
+ function (data)
+ {
+ cat("******************\n")
+
+ x1<-data[,1]
+ x2<-x1+rnorm(100,0,2)
+ xdiff<-x2-x1
+ corx1x2minx1<-cor(x1,xdiff)
+
+ y1<-data[,2]
+ y2<-y1+rnorm(100,10,2)
+ ydiff<-y2-y1
+ cory1y2miny1<-cor(y1,ydiff)
+
+ return(c(mean(x1),mean(x2),corx1x2minx1,
+ mean(y1),mean(y2),cory1y2miny1))
+ }


> boot(data=mommy,statistic=AdjForBase2,R=10) Error in statistic(data, original, ...) : unused argument(s) ( ...)

John Sorkin M.D., Ph.D.
Chief, Biostatistics and Informatics
Baltimore VA Medical Center GRECC and
University of Maryland School of Medicine Claude Pepper OAIC

University of Maryland School of Medicine Division of Gerontology
Baltimore VA Medical Center
10 North Greene Street
GRECC (BT/18/GR)
Baltimore, MD 21201-1524

410-605-7119
- NOTE NEW EMAIL ADDRESS:
jsorkin@grecc.umaryland.edu



R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Received on Sat Aug 13 13:28:35 2005

This archive was generated by hypermail 2.1.8 : Fri 03 Mar 2006 - 03:39:48 EST