Response variable has 2 levels. length of vector = 2000
I am requesting 10 groups
Why am I getting only 2?
Input of first 10
actual predicted
1 0 0
2 0 0
3 0 0
4 0 0
5 0 0
6 0 0
7 0 0
8 0 0
9 0 0
10 1 1
R code
library(gains)
gains(actual, predicted, groups=10,
ties.method=c("average"),
conf=c("normal"), boot.reps=1000, conf.level=0.95,
optimal=FALSE,percents=TRUE)
R Output
Depth Cume Cume Pct Mean
of Cume Resp Resp of Total Lift Cume Model
File N N Rate Rate Resp Index Lift Score
--------------------------------------------------------------------------
4 86 86 200.00% 200.00% 7.9% 183 183 200.00%
100 1914 2000 105.22% 109.30% 100.0% 96 100 100.00%