getIV: Compute the Given Binning IV

Description Usage Arguments Value See Also Examples

Description

getIV will compute the given binning IV of x variable, return a numeric.

Usage

1
getIV(df, cutbound, totalgood = NULL, totalbad = NULL)

Arguments

df

A dataframe only with two variables, X and Y.

cutbound

A single value for factor variable, or a vector with lbound and ubound for numeric variable.

totalgood

Default NULL. if not default, will use them directly, otherwise will recalculate based on df.

totalbad

Default NULL. if not default, will use them directly, otherwise will recalculate based on df.

Value

A numeric

See Also

Other WOE and IV computing functions: dfIV, getWOE, sumIV

Examples

1
2
3
4
5
6
data(CreditData)
getIV(CreditData[c("gender","target")], cutbound = "M")
getIV(CreditData[c("gscore","target")], cutbound = c(-Inf,534))
getIV(CreditData[c("gscore","target")], cutbound = c(577,617))
getIV(CreditData[c("gscore","target")], cutbound = c(617,Inf))
getIV(CreditData[c("gscore","target")], cutbound = NA)

xxzcool/scoremodel documentation built on May 4, 2019, 10:56 a.m.