Re: [R] Merge matrices with different column names

2012-10-26 Thread Rui Barradas
Hello, If you just want to write the matrices to a csv file instead of write.csv you can use write.table with options append=TRUE, sep=, and col.names=FALSE. If you want to merge (rbind) them, you can use code similar to pattern1 - (^var)[[:digit:]]+(.*$) pattern2 - (^var)_n_(.*$)

Re: [R] Merge matrices with different column names

2012-10-26 Thread Charles Determan Jr
Dennis, This works well and is exactly what I wanted for these matrices. Thank you very much, however, when I would try to export the resulting list it just is bound by columns. Now this isn't so bad for 2 matrices but I hope to apply this where there are many matrices and scrolling down a file

Re: [R] Merge matrices with different column names

2012-10-26 Thread arun
. - Original Message - From: Charles Determan Jr deter...@umn.edu To: Dennis Murphy djmu...@gmail.com Cc: r-help@r-project.org Sent: Friday, October 26, 2012 10:20 AM Subject: Re: [R] Merge matrices with different column names Dennis, This works well and is exactly what I wanted

[R] Merge matrices with different column names

2012-10-25 Thread Charles Determan Jr
A general question that I have been pursuing for some time but have set aside. When finishing some analysis, I can have multiple matrices that have specific column names. Ideally, I would like to combine these separate matrices for a final output as a csv file. A generic example: Matrix 1

Re: [R] Merge matrices with different column names

2012-10-25 Thread Jeff Newmiller
If they have the same number of rows, you can use cbind() to create one object to write out. --- Jeff NewmillerThe . . Go Live... DCN:jdnew...@dcn.davis.ca.usBasics: ##.#.