Displaying 2 results from an estimated 2 matches for "runmedian".
Did you mean:
runmean
2002 Sep 16
1
Running Median and Mean
...(Martin?) wanted to incorporate these functions into
an existing package or even "base"; otherwise I'll post the final product on
CRAN/src/contrib.
-- David Brahm (brahm@alum.mit.edu)
############### C Code: ##################
#include <R.h>
void runMedian(double *m, int *d, int *N) {
int i, j, k, a, R=(*N+1)/2, *r=(int*) R_alloc(*N, sizeof(int));
double old, new, *x;
for (j=1; j <= d[1]; j++) { /* Loop over columns */
x = m + j*d[0] - 1 - *N; /* x[*N] = m[nrow(m),j] */
for (i=0; i &l...
2007 Feb 20
1
baseline fitters
...ous alternative runmin() performs poorly due to dropout (zero-
and low-value 'reverse-spikes') in the data. And runmed fits a baseline that,
upon subtraction, obviously will send half the values into the negative, not
suitable for my application. I jimmied something together
with runmin and runmedian that is considerably faster; unfortunately,
the fit seems less good, at least by eye, due still to the bad runmin
behavior.
I'd be interested in other baseline fitting suggestions implemented
or implementable in R (I'm using v. 2.4.1pat under WinXP). Why, for
instance, can I not find a ru...