I have two dataframes and want to perform cbind and then write into a
file. The number of entries are more than a million in both frames. R is
taking a lot of time performing this operation.
Is there any alternate way to perform cbind?
x = table1[1:100,1:4]
y = table2[1:100,3:6]
For me, this example runs in a fraction of a second:
t1 - data.frame(matrix(rnorm(3e6),ncol=3))
t2 - data.frame(matrix(rnorm(3e6),ncol=3))
t3 - cbind(t1,t2)
dim(t3)
[1] 100 6
Maybe it takes longer if your data frames have other classes of objects in
them.
If some of your data frame
2 matches
Mail list logo