Dear ALL,
I have a column of data. The number of rows is 16000. Using resampling and
bootstrap function, I obtain a distribution of the mean of the data,
resampling up to 10000 (i.e. R=10,000).

But instead of the distribution of the mean or median, I wish to have a
distribution of fixed number of rows and fixed number of rows.

In order to do this,  I randomly chose a sample consisting of 16 data points
from the data series. With many overlap, data of length 16 (i.e. number of
rows in each sub sample =16) gave me 1000 columns of equal length. I
averaged the 1000 columns to get a single row by 16 column matrix.

I wish to repeat this random selection of equal length up  to 10,000 times
or so.

Is there a way I can manipulate the bootstrap function to do this. The code
I used to obtain the mean distribution is:

d<-read.table("KK",col.names=c("count"))
x =d$count
x=scale(x)
y=1:16000

d=c(1:16)
D<-data.frame(y,x)
D[d,]

samplemean <- function(x, d) {
  return(mean(x[d]))
}

samplemedian <- function(x, d) {
  return(median(x[d]))
}
#b = boot(x, samplemedian, R=10000)
b = boot(x, samplemean, R=10000)

plot(b)

Thanks for any help
Regards
Ogbos

	[[alternative HTML version deleted]]

