Re: [R] get sub elements

2015-05-10 Thread Boris Steipe
I think the "record number" i.e. the indices of the elements were asked for. That would be: which(5 <= allrecords & allrecords <= 9) Cheers, B. On May 10, 2015, at 7:33 AM, Rui Barradas wrote: > Hello, > > You should learn about indexing in R. Read the pdf R-intro.pdf that comes >

Re: [R] get sub elements

2015-05-10 Thread Rui Barradas
Hello, You should learn about indexing in R. Read the pdf R-intro.pdf that comes with your installation of R. allrecords[5 <= allrecords & allrecords <= 9] should do it. Hope this helps, Rui Barradas Em 10-05-2015 11:00, Ragia Ibrahim escreveu: Dear group I have this numeric object allrec

[R] get sub elements

2015-05-10 Thread Ragia Ibrahim
Dear group I have this numeric object allrecords 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 1 1 2 1 3 1 1 2 5 4 1 6 8 1 2 1 3 3 2 13 1 4 2 4 7 1 14 1 1 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 1 1