Skip to content
Back to formatted view

Raw Message

Message-ID: <6F23AB4F-B421-4ACC-911F-A385EBDDE816@comcast.net>
Date: 2012-02-06T15:49:05Z
From: David Winsemius
Subject: appending  variable's  values in table like fashion
In-Reply-To: <1328527768680-4360966.post@n4.nabble.com>

On Feb 6, 2012, at 6:29 AM, sagarnikam123 wrote:

> i have two variable
>> pyar
> [1] "M"  "12" "34" "13"
>> gita
> [1] "U"  "22" "33" "44"
> want to append gita object below pyar object as
> & want to take in anther variable
>

You could make a character matrix:

cmat <- matrix(c(pyar,gita), nrow=2, byrow=T)


> "M"  "12" "34" "13"
> "U"  "22" "33" "44"
>
> & write it in table fashion inside file

write.table(cmat, row.names=F, col.names=F)
"M" "12" "34" "13"
"U" "22" "33" "44"

-- 

David Winsemius, MD
West Hartford, CT