get_IV {autoScorecard} | R Documentation |
Function to Calculate IV Value
Description
Function to Calculate IV Value
Usage
get_IV(df, feat, label, E = 0, woeInf.rep = 1e-04)
Arguments
df |
A data.frame with independent variables and target variable. |
feat |
A name of dependent variable. |
label |
A name of target variable. |
E |
Constant, should be set to [0,1], used to prevent calculation overflow due to no data in binning. |
woeInf.rep |
Woe replaces the constant, and when woe is positive or negative infinity, it is replaced by a constant. |
Value
A data frame including counts, proportions, odds, woe, and IV values for each stratum.
Examples
accepts <- read.csv( system.file( "extdata", "accepts.csv", package = "autoScorecard" ))
feature <- stats::na.omit( accepts[,c(1,3,7:23)] )
iv1 = get_IV( df= feature ,feat ='tot_derog' , label ='bad_ind' )
[Package autoScorecard version 0.3.0 Index]