Re: [R] matrix position to list of coordinates

2012-01-02 Thread Willi Richert
Hi Ana, most probably this is one of the more ugly solutions: > d=dim(A) > d [1] 2 4 > cbind(rep(1:d[1], each=d[2]), rep(1:d[2], d[1])) [,1] [,2] [1,]11 [2,]12 [3,]13 [4,]14 [5,]21 [6,]22 [7,]23 [8,]24 Thanks, wr * Ana [2012

Re: [R] matrix position to list of coordinates

2012-01-02 Thread Willi Richert
Hi Ana, > d=dim(A) > d [1] 2 4 > cbind(rep(1:d[1], each=d[2]), rep(1:d[2], d[1])) [,1] [,2] [1,]11 [2,]12 [3,]13 [4,]14 [5,]21 [6,]22 [7,]23 [8,]24 Thanks, wr * Ana [2012-01-01 23:21:12 +0100]: > How can I extract a list of

Re: [R] matrix position to list of coordinates

2012-01-01 Thread Willi Richert
Hi Ana, most probably this is one of the more ugly solutions: > d=dim(A) > d [1] 2 4 > cbind(rep(1:d[1], each=d[2]), rep(1:d[2], d[1])) [,1] [,2] [1,]11 [2,]12 [3,]13 [4,]14 [5,]21 [6,]22 [7,]23 [8,]24 Thanks, wr * Ana [2012-

[R] Density over time intervals

2011-11-23 Thread Willi Richert
Hello R community, I have recorded online/offline timestamps per user that looks like this: username,online_time,offline_time a,2011-11-01 16:16:56.692572+01,2011-11-01 21:06:16.388903+01 a,2011-11-01 21:07:14.204367+01,2011-11-01 21:34:21.47081+01 a,2011-11-01 21:38:09.501356+01,2011-11-01 21:53

[R] Density over time intervals

2011-11-23 Thread Willi Richert
Hi, I have recorded online/offline timestamps per user that looks like this: username,online_time,offline_time a,2011-11-01 16:16:56.692572+01,2011-11-01 21:06:16.388903+01 a,2011-11-01 21:07:14.204367+01,2011-11-01 21:34:21.47081+01 a,2011-11-01 21:38:09.501356+01,2011-11-01 21:53:45.272321+