Displaying 1 result from an estimated 1 matches for "merge0".
Did you mean:
merge
2007 Feb 01
3
Lining up x-y datasets based on values of x
Hi,
I was wondering if there is a direct approach for lining up 2-column
matrices according to the values of the first column. An example and a
brute-force approach is given below:
x <- cbind(1:10, runif(10))
y <- cbind(5:14, runif(10))
z <- cbind((-4):5, runif(10))
xx <- seq( min(c(x[,1],y[,1],z[,1])), max(c(x[,1],y[,1],z[,1])), 1)
w <- cbind(xx, matrix(rep(0, 3*length(xx)),