ch 14, 2012 1:02 AM
To: William Dunlap
Cc: r-help@r-project.org
Subject: Re: [R] reshaping a dataset for a network
Thank you fro the reply.
I managed to arrive till here, then I would like to have it in matrix
where the $1 $2...$5 are the first column.
Il 3/13/2012 8:15 PM, William Dunlap ha scritto
nal Message-
> From: Marco Guerzoni [mailto:marco.guerz...@unito.it]
> Sent: Wednesday, March 14, 2012 1:02 AM
> To: William Dunlap
> Cc: r-help@r-project.org
> Subject: Re: [R] reshaping a dataset for a network
>
> Thank you fro the reply.
> I managed to arrive till here, t
g]
On Behalf
Of Marco Guerzoni
Sent: Tuesday, March 13, 2012 10:51 AM
To: r-help@r-project.org
Subject: [R] reshaping a dataset for a network
dear all,
apologizes for bothering with a probably stupid question but I really
don' t know how to proceed.
I have a dataset which look like df
a<-
;> that your df suggests you want. Use df<-data.frame(a,b) to make
>> a data.frame. Then you could do with(df, split(a,b)) to operate on
>> the a and b in the data.frame df.
>>
>> Bill Dunlap
>> Spotfire, TIBCO Software
>> wdunlap tibco.com
>>
>>
-help-boun...@r-project.org] On
Behalf
Of Marco Guerzoni
Sent: Tuesday, March 13, 2012 10:51 AM
To: r-help@r-project.org
Subject: [R] reshaping a dataset for a network
dear all,
apologizes for bothering with a probably stupid question but I really
don' t know how to proceed.
I have a d
r-project.org] On
> Behalf
> Of Marco Guerzoni
> Sent: Tuesday, March 13, 2012 10:51 AM
> To: r-help@r-project.org
> Subject: [R] reshaping a dataset for a network
>
> dear all,
> apologizes for bothering with a probably stupid question but I really
> don' t kn
dear all,
apologizes for bothering with a probably stupid question but I really
don' t know how to proceed.
I have a dataset which look like df
a <- c(1,2,3,4,4,4,5,5)
b <- c(11,7,4,9,8,3,12,4)
df <-cbind(a,b)
I would like to have one which looks like this:
a
1 11
2 7
3 4
4 9 8 3
5 12 4
a a
7 matches
Mail list logo