[R] another resampling question
Jan M. Wiener
jan.wiener at tuebingen.mpg.de
Fri Oct 26 09:25:49 CEST 2007
Hello,
I do have a question regarding resampling of data (matrices). Imagine
having 2 data sets, organized in a matrix with two columns, the first
column being, eg, traveled distance, the second column being some
dependent variable. I now have 2 data sets from two subjects covering
the same distance but differing in the number of samples: say subj1 was
faster, producing 1000 samples along his/her way, while subj2 was slower
producing 1100 samples. Now I would like these two matrices to be of the
same length (same number of rows). Obviously, it would be most easy to
down-sample the larger data set, either (1) by dropping every 10th
sample, or by (2) completely recalculating and interpolating the data.
As i have lots of data, i would like to benefit from existing functions
to do either 1 or 2, best both variants. Does anyone know of such functions?
Thanks in advance,
jan
More information about the R-help
mailing list