[R] data.frame to array?

2009-04-03 Thread rkevinburton
I have a list of data.frames str(bins) List of 19217 $ 100026:'data.frame': 1 obs. of 6 variables: ..$ Sku : chr 100026 ..$ Bin : chr T149C ..$ Count: int 108 ..$ X: int 20 ..$ Y: int 149 ..$ Z: chr 3 $ 100030:'data.frame': 1 obs. of 6 variables: ... As you can

Re: [R] data.frame to array?

2009-04-03 Thread Gavin Simpson
On Fri, 2009-04-03 at 11:45 -0700, rkevinbur...@charter.net wrote: I have a list of data.frames str(bins) List of 19217 $ 100026:'data.frame': 1 obs. of 6 variables: ..$ Sku : chr 100026 ..$ Bin : chr T149C ..$ Count: int 108 ..$ X: int 20 ..$ Y: int 149

Re: [R] data.frame to array?

2009-04-03 Thread David Winsemius
I do not think that the form [[1:3]] is legit. ltest - list( a, b, c, d) ltest[[1:3]] Error in ltest[[1:3]] : recursive indexing failed at level 2 You might try with single brackets: ltest[1:3] [[1]] [1] a [[2]] [1] b [[3]] [1] c -- David Winsemius On Apr 3, 2009, at 2:45 PM,

Re: [R] data.frame to array?

2009-04-03 Thread hadley wickham
On Fri, Apr 3, 2009 at 1:45 PM, rkevinbur...@charter.net wrote: I have a list of data.frames str(bins) List of 19217  $ 100026:'data.frame': 1 obs. of  6 variables:  ..$ Sku  : chr 100026  ..$ Bin  : chr T149C  ..$ Count: int 108  ..$ X    : int 20  ..$ Y    : int 149  ..$ Z    : chr

Re: [R] data.frame to array?

2009-04-03 Thread Wacek Kusnierczyk
David Winsemius wrote: I do not think that the form [[1:3]] is legit. sure it is. ltest - list( a, b, c, d) ltest[[1:3]] Error in ltest[[1:3]] : recursive indexing failed at level 2 read the error message: *recursive* indexing failed. that's because ltest[[1]] has only one element