calcPSI: Calculates the population stability index for two sample...

Description Usage Arguments Author(s) Examples

Description

Calculates the population stability index for two sample variables

Usage

1
calcPSI(data, var, valvar, breaks = 10)

Arguments

data

The dataset that contains the two variables for comparison

var

The development variable or score used to set the distribution

valvar

The validation variable to compare against the development variable

breaks

The number of bins to break the development variable for stability testing. Default is decile distribution.

Author(s)

Helena Ristov

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
## Not run: 
x1      <- runif(1000, 1, 10)
x1_val  <- runif(1000, 1, 10)

random <- sample(c(0,1),1)
for(i in 1:999){
randomnext <- sample(c(0,1),1)
random     <- c(random, randomnext)
 
}

test <- cbind(x1, x1_val, random)
calPSI(test, 'x1', 'x1_val')

## End(Not run)

helenristov/aCompiler documentation built on May 3, 2019, 9:40 p.m.