search for: twiceit

Displaying 1 result from an estimated 1 matches for "twiceit".

Did you mean: twice
2010 Nov 03
1
smooth: differences between R and S-PLUS
.... Nicola ### EXAMPLE # Comments indicates which step of the 4(3RSR)2H algorithm I try to replicate. # Data x1 <- c(4, 1, 3, 6, 6, 4, 1, 6, 2, 4, 2) # 4 out = NULL for (i in 1:11) {out[i] = median(x1[i:(i+3)])} out[is.na(out)] = x1[is.na(out)] out # (3RSR) x2 = smooth(out, "3RSR", twiceit = F) x2 # 2 out2 = NULL for (i in 1: 11) {out2[i] = median(x2[i:(i+1)])} out2[is.na(out2)] = x2[is.na(out2)] out2 # H filter(out2, filter = c(1/4, 1/2, 1/4), sides = 2) [[alternative HTML version deleted]]