Re: [R] help counting in data

2012-08-11 Thread jim holtman
use 'dput' to enclose your data. I think 'cut' is what you want: > dput(x) c(0, 1.179, 3.729, 9.418, 18.01, 29.746, 58.662, 131.566, 2323.7 ) > dput(y) c(5.79, 1579.52, 2323.7, 68.85, 426.07, 110.29, 108.29, 1067.6, 17.05, 22.66, 21.02, 175.88, 139.07, 144.12, 20.46, 43.4, 194.9, 47.3, 7.74, 0.4,

Re: [R] help counting in data

2012-08-11 Thread arun
t3leftajmax)|(dat3>leftajmin & dat3 To: r-help@r-project.org Cc: Sent: Saturday, August 11, 2012 9:59 AM Subject: [R] help counting in data Hi >i have this data > X [1]    5.79 1579.52 2323.70  68.85  426.07  110.29  108.29 1067.60  17.05  22.66 [11]  21.02  175.88  139.0

Re: [R] help counting in data

2012-08-11 Thread Rui Barradas
Hello, Post your data using dput(). Copy the output of dput(X) and paste it in a post. Anyway, you can try the following. sum( leftaj <= X & X <= rightaj ) Hope this helps, Rui Barradas Em 11-08-2012 14:59, hafida escreveu: Hi i have this data X [1]5.79 1579.52 2323.70 68.85 4

[R] help counting in data

2012-08-11 Thread hafida
Hi >i have this data > X [1]5.79 1579.52 2323.70 68.85 426.07 110.29 108.29 1067.60 17.05 22.66 [11] 21.02 175.88 139.07 144.12 20.46 43.40 194.90 47.307.74 0.40 [21] 82.859.88 89.29 215.101.750.79 15.933.910.27 0.69 [31] 100.58 2