Re: [R] Selecting cases from matrices stored in lists

2011-08-22 Thread mdvaan
Thanks Jean, changing c[[t]] to c[[year]] solved the issue. Math Jean V Adams wrote: > >> Re: [R] Selecting cases from matrices stored in lists >> mdvaan >> to: >> r-help >> 08/22/2011 09:46 AM >> >> Jean V Adams wrote: >> > &

Re: [R] Selecting cases from matrices stored in lists

2011-08-22 Thread Jean V Adams
> Re: [R] Selecting cases from matrices stored in lists > mdvaan > to: > r-help > 08/22/2011 09:46 AM > > Jean V Adams wrote: > > > >> [R] Selecting cases from matrices stored in lists > >> mdvaan > >> to: > >> r-help > >>

Re: [R] Selecting cases from matrices stored in lists

2011-08-22 Thread Gabor Grothendieck
On Mon, Aug 22, 2011 at 9:07 AM, Jean V Adams wrote: >> [R] Selecting cases from matrices stored in lists >> mdvaan >> to: >> r-help >> 08/22/2011 07:24 AM >> >> Hi, >> >> I have two lists (c and h - see below) containing matrices with simila

Re: [R] Selecting cases from matrices stored in lists

2011-08-22 Thread mdvaan
Jean V Adams wrote: > >> [R] Selecting cases from matrices stored in lists >> mdvaan >> to: >> r-help >> 08/22/2011 07:24 AM >> >> Hi, >> >> I have two lists (c and h - see below) containing matrices with similar >> cases but

Re: [R] Selecting cases from matrices stored in lists

2011-08-22 Thread Jean V Adams
> [R] Selecting cases from matrices stored in lists > mdvaan > to: > r-help > 08/22/2011 07:24 AM > > Hi, > > I have two lists (c and h - see below) containing matrices with similar > cases but different values. I want to split these matrices into multiple >

[R] Selecting cases from matrices stored in lists

2011-08-22 Thread mdvaan
Hi, I have two lists (c and h - see below) containing matrices with similar cases but different values. I want to split these matrices into multiple matrices based on the values in h. So, I did the following: years<-c(1997:1999) for (t in 1:length(years)) { year=as.character(ye