It was a great help Phil!
but I was in some doubts with the cut command, so I develop this program
using the Ntil formula
in this case vigntil or NTIL(20) and NTIL(10) respectively, but definitely
thanks again!!!
lk<-c(12,23,34,13,45,56)
> cut(lk,quantile(lk,(0:20)/20),labels=FALSE,include.lowes
On Wed, Jun 16, 2010 at 7:10 PM, J. Arturo Coral Alamo
wrote:
> I'm trying to find a similar function as decile of SPSS, NTILES (10)
> some of you know about that, I will appreciate your help in advance.
See quantcut in the Hmisc package.
__
R-help@r
Arturo -
Something like
cut(x,quantile(x,(0:10)/10),labels=FALSE,include.lowest=TRUE)
should give you what you want.
- Phil Spector
Statistical Computing Facility
Depart
>
> Hello comunity,
>
> I'm trying to find a similar function as decile of SPSS, NTILES (10)
> some of you know about that, I will appreciate your help in advance.
>
> In SPSS
> VARIABLES=Sales (A) /NTILES (10) /PRINT=NO
>
> for example if I have Next data input:
>
> case IdCustSales Profit
Hello comunity,
I'm trying to find a similar function as decile of SPSS, NTILES (10)
some of you know about that, I will appreciate your help in advance.
In SPSS
VARIABLES=Sales (A) /NTILES (10) /PRINT=NO
for example if I have Next data input:
case IdCust Sales Profit 1 265 140.81 314.31 2 2
5 matches
Mail list logo