Recently, a series of divergence measures have emerged from information theory and statistics and numerous inequalities have been established among them. However, none of them are a metric in topology. In this paper, we propose a class of metric divergence measures, namely, Lp(P∥Q), P≥1, and study their mathematical properties. We then study an important divergence measure widely used in credit scoring, called information value. In particular, we explore the mathematical reasoning of weight of evidence and suggest a better alternative to weight of evidence. Finally, we propose using Lp(P∥Q) as alternatives to information value to overcome its disadvantages.
1. Introduction
The information measure is an important concept in Information theory and statistics. It is related to the system of measurement of information or the amount of information based on the probabilities of the events that convey information. Divergence measures are an important type of information measures. They are commonly used to find appropriate distance or difference between two probability distributions.
Let
(1)Δn={P=(p1,p2,…,pn)∣pi≥0,∑i=1npi=1},n≥2,
be the set of finite discrete probability distributions as in [1]. For all P, Q∈Δn, the following divergence measures are well known in the literature of information theory and statistics.
Shannon’s Entropy [3].(3)H(P)=-∑i=1npilog2(pi),
which is sometimes referred to as measure of uncertainty. The entropy H(P) of a discrete random variable is defined in terms of its probability distribution P and is a good measure of randomness or uncertainty.
Note that in the original definition of Shannon’s Entropy the log is to the base 2 and entropy is expressed in bits in information theory. The log can be any other bases and the entropy will be a constant factor of the one in base 2 by the change-base formula of the logarithm function. Hence, without loss of generality, we will assume all the logs are natural logarithms.
Kullback and Leibler’s Relative Information [4].(4)D(P∥Q)=∑i=1npiln(piqi).
Its symmetric form is the well-known J-divergence.
J-Divergence (Jeffreys [5], Kullback, and Leibler [4]).(5)J(P∥Q)=D(P∥Q)+D(Q∥P)=∑i=1n(pi-qi)ln(piqi).
Symmetric Chi-Square Divergence (Dragomir et al. [7]). One has
(7)ψ(P∥Q)=χ2(P∥Q)+χ2(Q∥P)=∑i=1n(pi-qi)2(pi+qi)piqi,
where χ2(P∥Q)=∑i=1n((pi-qi)2/pi) is the well-known χ2-divergence (Pearson [8]).
Jensen-Shannon Divergence (Sibson [9], Burbea, and Rao [10, 11]).(8)I(P∥Q)=12[∑i=1npiln(2pipi+qi)+∑i=1nqiln(2qipi+qi)].
Taneja’s Divergence (Taneja [12]). One has
(10)d(P∥Q)=1-∑i=1n(pi+qi2)(pi+qi2).
The information measures J(P∥Q), I(P∥Q) and T(P∥Q) can be written as
(11)J(P∥Q)=4[I(P∥Q)+T(P∥Q)],I(P∥Q)=12[D(P∥P+Q2)+D(Q∥P+Q2)],T(P∥Q)=12[D(P+Q2∥P)+D(P+Q2∥Q)].
Relative Information of Type s. Cressie and Read [13] considered the one-parametric generalization of information measure D(P∥Q), called the relative information of type s given by
(12)Ds(P∥Q)=[s(s-1)]-1[∑i=1npisqi1-s-1],s≠0,1.
It also has some special cases:
lims→0Ds(P∥Q)=D(Q∥P),
lims→1Ds(P∥Q)=D(P∥Q),
D-1(P∥Q)=(1/2)ψ2(Q∥P),
D1/2(P∥Q)=4h(P∥Q),
D2(P∥Q)=(1/2)ψ2(P∥Q),
D2(P∥Q)=D-1(Q∥P),
D1(P∥Q)=D0(Q∥P).
It is shown that Ds(P∥Q) is nonnegative and convex in P and Q in [1].
J-Divergence of Type s [14].(13)Vs(P∥Q)=Ds(P∥Q)+Ds(Q∥P)=[s(s-1)]-1[∑i=1n(pisqi1-s+qispi1-s)-2],s≠0,1.
It admits the following particular cases:
lims→0Vs(P∥Q)=lims→1Vs(P∥Q)=J(P∥Q),
lims→1Vs(P∥Q)=J(P∥Q),
V-1(P∥Q)=V2(P∥Q)=(1/2)Ψ(P∥Q),
V0(P∥Q)=V1(P∥Q)=J(P∥Q),
V1/2(P∥Q)=8h(P∥Q).
Unified Generalization of Jensen-Shannon Divergence and Arithmetic-Geometry Mean Divergence [14].(14)Ws(P∥Q)=12[Ds(P+Q2∥P)+Ds(P+Q2∥Q)].
It admits the following particular cases:
W-1(P∥Q)=(1/4)Δ(P∥Q),
W0(P∥Q)=I(P∥Q),
W1/2(P∥Q)=4d(P∥Q),
W1(P∥Q)=T(P∥Q),
W2(P∥Q)=(1/16)Ψ(P∥Q).
Taneja proved [14] that all the 3 s-type information measures Ds(P∥Q), Vs(P∥Q), and Ws(P∥Q) are nonnegative and convex in the pair (P,Q). He also obtained inequalities regarding the various divergence measures:
(15)14Δ(P∥Q)≤I(P∥Q)≤h(P∥Q)≤4d(P∥Q)≤18J(P∥Q)≤T(P∥Q)≤116ψ(P∥Q).
Here, we observe thatΔ(P∥Q)>0. Hence, from the above inequalities we see that I(P∥Q), h(P∥Q), d(P∥Q), J(P∥Q), T(P∥Q), and ψ(P∥Q) are all positive.
We also note that all pi in the original definition of Δn in [1] are required to be positive. Yet, in realty some pi may be 0. In this case I(P∥Q), T(P∥Q), ψ(P∥Q), and Δ(P∥Q) will be undefined. We have extended the definition of Δn to include the cases when pi=0. We assume that 0ln(0)=0, which is easily justified by continuity since xln(x)→0 as x→0. For convenience, we also assume 0ln(0/0)=0 and tln(t/0)=0 for t>0.
A problem with the above divergence measures is that none of them are a real distance, that is, a metric, in topology. In this paper, we will study a class of metric divergence measures Lp(P∥Q). We then study the underlying mathematics of a special divergence measure called information value, which is widely used in credit scoring. We propose using Lp(P∥Q) as alternatives to IV in order to overcome the disadvantages of information value.
The rest of this paper is organized as follows. In Section 2, after reviewing the metric space, we disprove that the above divergence measures are metrics. We then study a class of metric divergence measures Lp(P∥Q). Section 3 is concerned with information value. We examine a rule of thumb and weight of evidence and suggest a better alternative to weight of evidence. We then propose using Lp(P∥Q) as alternatives of IV to overcome the disadvantages of information value. Section 4 presents some numerical results. Finally, the paper is concluded in Section 5.
2. Metric Divergence Measures 2.1. Review of Metric SpaceDefinition 1.
Suppose a real valued function d:M×M→R and that for all x, y, z of set M
d(x,y)≥0 (nonnegative),
d(x,x)=0 if and only if x=y (identity),
d(x,y)=d(y,x) (symmetry),
d(x,z)≤d(x,y)+d(y,z) (triangle inequality).
Such a “distance function” d is called a metric on M, and the pair (D,M) is called a metric space. If d satisfies (1)–(3) but not necessarily (4), it is called a semimetric.
A metric space is a topological space in a natural manner, and therefore all definitions and theorems about general topological spaces also apply to a metric space. For instance, in a metric space one can define open and closed sets, convergence of sequences of points, compact space, and connected space.
Definition 2.
A metric d1 is said to be upper bounded by another metric d2 if there exists a positive constantcsuch that d1(x,y)≤c×d2(x,y) for all x, y∈M. In this case, d2 is said to be lower bounded byd1.
If d1 is upper bounded by d2, then the convergence in the metric space (M,d2) implies the convergence in the metric space (M,d1).
Definition 3.
Two metrics d1 and d2 are equivalent if there exist 2 positive constants α and β such that α×d2(x,y)≤d1(x,y)≤β×d2(x,y).
If two metrics d1 and d2 are equivalent, they will have the same convergence.
2.2. Nonmetric Divergence Measures Proposition 4.
None of the divergence measuresΔ(P∥Q), I(P∥Q), h(P∥Q), d(P∥Q), J(P∥Q), T(P∥Q), and ψ(P∥Q) are a metric in topology. Indeed, none of them satisfy the triangle inequality.
Proof.
We disprove them either numerically or analytically by constructing counter examples in Δ2.
Letp=(0,1), q=(1,0), and r=(0.5,0.5). ThenΔ(P∥Q)=2, Δ(P∥R)=Δ(R∥Q)=2/3, andΔ(P∥R)+Δ(R∥Q)=4/3<2=Δ(P∥Q).
Letp=(0.5,0.5), q=(0.2,0.8), and r=(0.3,0.7). Then I(P∥Q)=0.02357767, I(R∥Q)=0.00350105, I(P∥R)=0.01020550, and I(P∥R)+I(R∥Q)<I(P∥Q).
Letp=(0,1), q=(1,0), and r=(0.5,0.5). Thenh(P,Q)=1, h(P∥R)=h(R∥Q)=(1/2)(2-2), and h(P∥R)+h(R∥Q)=2-2<1=h(P∥Q).
Let p=(0.2,0.8), q=(0.4,0.6), and r=(0.3,0.7). Then
(16)D(P∥R)+D(R∥Q)-D(P∥Q)=0.2×ln23+0.8×ln87+0.3×ln34+0.7×ln76-0.2×ln12-0.8×ln43=0.2(ln23-ln12)+0.8(ln87-ln43)+0.3×ln34+0.7×ln76=0.2×ln43+0.8×ln67+0.3×ln34+0.7×ln76=0.2×ln43+0.8×ln67-0.3×ln43-0.7×ln67=-0.1×ln43+0.1×ln67=0.1(ln67-ln43)=0.1×ln914<0.1×ln1=0.
Hence,D(P∥R)+D(R∥Q)<D(P∥Q). Indeed, D(P∥Q) is not symmetric either (see [15]).
Letp=(0.2,0.8), q=(0.4,0.6), r=(0.3,0.7). Then
(17)J(P∥R)+J(R∥Q)=(0.1×ln32+0.1×ln87)+(0.1×ln43+0.1×ln76)=0.1×ln83,J(P∥Q)=0.2×ln2+0.2×ln43=0.2×ln83.
Hence,J(P∥R)+J(R∥Q)<J(P∥Q).
Letp=(0.5,0.5),q=(0.2,0.8), and r=(0.3,0.7). Then T(P∥Q)=0.05330024, T(P∥R)=0.02135897, T(R∥Q)=0.00677313, andT(P∥R)+T(R∥Q)<T(P∥Q).
Let p=(0.5,0.5), q=(0.2,0.8), r=(0.3,0.7). Then, ψ(P∥Q)=369/400, ψ(Q∥R)=185/1680, ψ(P∥R)=368/1050, and ψ(P∥R)+ψ(R∥Q)<ψ(P∥Q).
2.3. A Natural Metric Divergence Measure
If we pick up the common part of D(P∥Q) and J(P∥Q), we will obtain a metric divergence measure
(18)Z(P∥Q)=∑i=1n|ln(pi)-ln(qi)|=∑i=1n|ln(piqi)|.
Sincepi≤1and|pi-qi|≤1 for all1≤i≤n, bothD(P∥Q)andJ(P∥Q)are upper bounded byZ(P∥Q); that is, D(P∥Q)≤Z(P∥Q), J(P∥Q)≤Z(P∥Q).
Recall that for a real number p≥1, thelp-norm of vectorx=(x1,x2,…,xn)∈Rnis defined by
(19)∥x∥p=(∑i=1n|xi|p)1/p.
We will apply thelp-metric from thelp-norm to divergence measures to obtainlp-divergence. For convenience, we will use the upper case notation.
Definition 5.
For two probability distributionsPandQ, one defines their Lp-divergence as
(20)Lp(P∥Q)=∑i=1n|pi-qi|pp.
Here,p≥1is used for superscript, subscript, and radial root. It should not be confused with the vectorP.
In particular, whenp=1, we have the L1 distance:
(21)L1(P∥Q)=∑i=1n|pi-qi|.
Whenp=2, we obtain the Euclidean Distance:
(22)L2(P∥Q)=∑i=1n(pi-qi)2.
Whenp→∞, we have
(23)L∞(P∥Q)=max1≤i≤n|pi-qi|.
It is known thatlp-norms are decreasing inp. Moreover, alllpmetrics are equivalent.
Lemma 6.
Ifr>p≥1, then thelp-norms inRnsatisfy
(24)∥x∥r≤∥x∥p≤n(1/p-1/r)∥x∥r.
Corollary 7.
Ifr>p≥1, then theLp-divergences satisfy
(25)Lr(P∥Q)≤Lp(P∥Q)≤n(1/p-1/r)Lr(P∥Q).
Theorem 8.
Lp-divergences are all bounded by constant 2 forp≥1; that is,Lp(P∥Q)≤2.In particular,L∞(P∥Q)≤1andL2(P∥Q)≤2.
Proof.
We first prove the general case. From Corollary 7, it is sufficient to prove that theL1-divergence is bounded by 2. LetP=(p1,p2,…,pn)andQ=(q1,q2,…,qn)be two probability distributions. Without loss of generality, let us assume thatp1≥q1, p2≥q2,…,pk≥qk, and pk+1<qK+1,…,pn<qn. Then, we have
(26)L1(P∥Q)=∑i=1n|pi-qi|=∑i=1k(pi-qi)+∑i=k+1n(qi-pi)≤∑i=1kpi+∑i=k+1nqi≤∑i=1npi+∑i=1nqi=1+1=2.
Noting that |pi-qi|≤1for1≤i≤n, we have(pi-qi)2≤|pi-qi|≤1.Hence,
(27)L∞(P∥Q)=max1≤i≤n|pi-qi|≤1,L2(P∥Q)=∑i=1n(pi-qi)2≤∑i=1n|pi-qi|=L1(P∥Q)≤2.
Therefore, we have proved the 2 particular cases.
The following result shows that the relative entropyD(P∥Q)is lower bounded by the square of theL1(P∥Q). Its proof can be found at [15].
Lemma 9.
(28)D(P∥Q)≥12(L1(P∥Q))2.
Theorem 10.
The square root of J(P∥Q) is lower bounded byL1(P∥Q); that is,
(29)J(P∥Q)≥L1(P∥Q).
Proof.
Applying lemma toD(P∥Q)andD(Q∥P), we obtain
(30)D(P∥Q)+D(Q∥P)≥12(L1(P∥Q))2+12(L1(Q∥P))2=(L1(P∥Q))2.
Note that the left hand side is nothing butJ(P∥Q).The proof is completed by taking the square root on both sides.
Remark 11.
J(P∥Q)and henceJ(P∥Q)are unbounded by any constants. This can be seen by takingP=(s,1-s)andQ=(1-s,s), 0<s<1, and taking limit s→0.SinceLp-divergences are all bounded by constant 2 forp≥1, J(P∥Q)and henceJ(P∥Q)are not equivalent toLp-divergences.
We now establish the convexity property for Lp-divergence, which is useful in optimization.
Theorem 12.
Lp(P∥Q)is convex in the pair(p,q), that is, if(P1,Q1), and(P2,Q2)are two pairs of probability distributions, then
(31)Lp(λP1+(1-λ)P2∥λQ1+(1-λ)Q2)≤λLp(P1∥Q1)+(1-λ)Lp(P2∥Q2)
for all0≤λ≤1.
Proof.
Let P1=(p11,p12,…,p1n), P2=(p21,p22,…,p2n),Q1=(q11,q12,…,q1n), and Q2=(q21,q22,…,q2n). Then
(32)Lp(λP1+(1-λ)P2∥λQ1+(1-λ)Q2)=(∑i=1n|λp1i+(1-λ)p2i-λq1i-(1-λ)q2i|p)1/p=(∑i=1n|λ(p1i-q1i)+(1-λ)(p2i-q2i)|p)1/p≤(∑i=1n|λ(p1i-q1i)|p)1/p+(∑i=1n|(1-λ)(p2i-q2i)|p)1/p=(λ∑i=1n|(p1i-q1i)|p)1/p+(1-λ)(∑i=1n|(p2i-q2i)|p)1/p=λLp(P1∥Q1)+(1-λ)Lp(P2∥Q2).
Here, the first inequality is from the well-known Minkowski’s Inequality.
It follows from the following results that we can generate infinitely many metric divergence measures using the existing ones.
Proposition 13.
If d1(P∥Q) and d2(P∥Q) are two metric divergence measures, so are the following 3 measures:
α×d1(P∥Q)+β×d2(P∥Q) for all α≥0, β≥0 and α+β>0,
max(d1(P∥Q),d2(P∥Q)),
(d1(P∥Q))2+(d2(P∥Q))2.
Proof.
The proof of (1) and (2) is trivial and hence will be omitted. As for (3), it is sufficient to verify the triangle inequality since nonnegative, identity, and symmetry are all easy to verify.
To begin with, let us first prove an inequality: for any nonnegativea,b,c,d,
(33)a2+b2+c2+d2+2ac+2bd≤a2+b2+c2+d2.
It is easy to see that inequality (33) is equivalent to the following inequality:
(34)ac+bd≤(a2+b2)(c2+d2).
Inequality (34) is equivalent to the following inequality:
(35)2abcd≤a2d2+b2c2.
Inequality (35) is equivalent to the following inequality:
(36)(ad-bc)2≥0.
Since inequality (36) is always true, inequality (34) is true.
Now, let us assumeP, Q, R are 3 arbitrary probability distributions. Sinced1(P∥Q)andd2(P∥Q)satisfy the triangle inequality, we have
(37)(d1(P∥Q))2+(d2(P∥Q))2≤([d1(P∥R)+d1(R∥Q)]2+[d2(P∥R)+d2(R∥Q)]2)1/2=(d12(P∥R)+2d1(P∥R)d1(R∥Q)+d12(R∥Q)+d22(P∥R)+2d2(P∥R)×d2(R∥Q)+d22(R∥Q))1/2=([d12(P∥R)+d22(P∥R)]+[d12(R∥Q)+d22(R∥Q)]+2d1(P∥R)d1(R∥Q)[d12(P∥R)+d22(P∥R)]+2d2(P∥R)d2(R∥Q))1/2≤d12(P∥R)+d22(P∥R)+d12(R∥Q)+d22(R∥Q).
The last inequality results from inequality (33).
Remark 14.
da Costa and Taneja [16] show that Ws(P∥Q) and Vs(P∥Q) are metrics divergence measures for all s. SinceΔ(P∥Q), I(P∥Q), h(P∥Q), d(P∥Q), J(P∥Q), T(P∥Q), and ψ(P∥Q) are all constant factors of special cases of Ws(P∥Q) or Vs(P∥Q), they are all metric divergence measures by Proposition 13. Yet, da Costa and Taneja did not disprove or discuss any applications of these divergence measures.
3. Information Value in Credit Scoring
Information value, or IV in short, is a widely used measure in credit scoring in the financial industry. It is a numerical value to quantify the predictive power of an independent continuous variablexin capturing the binary dependent variabley. Mathematically, it is defined as [17]
(38)IV=∑i=1n(gig-bib)×ln(gi/gbi/b),
where n is the number of bins or groups of variable x, gi and bi are the numbers of good and bad accounts with bini, and g and b are the total number of good accounts and bad accounts in the population. Hence,gi/gandbi/bare distributions of good accounts and bad accounts. Therefore,
(39)∑i=1ngig=∑i=1nbib=1.
Usually, “good” means y=0 and “bad” means y=1. It could be the other way, since IV is symmetric about good and bad. If gi/g=bi/b for alli=1,…,n, then IV = 0; that is, x has no information on y.
IV is mainly used to reduce the number of variables as the initial step in the logistic regression, especially in big data with many variables. IV is based on an analysis of each individual predictor in turn without taking into account the other predictors.
3.1. IV and WOE
One advantage of IV is its close tie with weight of evidence (WOE), defined by ln((gi/g)/(bi/b)).WOE measures the strength of each grouped attribute in separating good and bad accounts. According to [17], WOE is the log of odds ratio, which measures odds of being good. Moreover, WOE is monotonic and linear.
Yet, WOE is not an accurate measure in that it is not the log of odds ratio and hence its linearity is not guaranteed. Indeed, gi/g and bi/b are from two different probability distributions. They represent the number of good accounts in binidivided by the total number of good accounts in the population and the number of bad accounts in binidivided by the total number of bad accounts in the population, respectively. In general, gi/g+bi/b≠1 as can be seen from Exhibit 6.2 in [17].
To make WOE a log of odds, let us change its definition to
(40)WOE1=ln(gi/nibi/ni)=ln(gibi)=-ln(bigi)
and denote it by WOE1. The cancelled ni=gi+bi is the number of accounts in bini, and so gi/ni+bi/ni=1.
As is well known, the logistic regression models the log odds, expressed in conditional probabilities, as a linear function of the independent variable; that is,
(41)ln(P(Y=1∣x)P(Y=0∣x))=β0+β1x.
When x falls into bin i, ln(P(Y=1∣x)/P(Y=0∣x)) becomes ln(bi/gi)=-ln(gi/bi). Hence, the WOE1 values are either continuously increasing or continuously decreasing in a linear fashion.
IV and WOE1 can be used together to select independent variables for logistic regression. When a continuous variable x has a large IV, we make it a candidate variable for logistic regression if WOE1 values are linear. It is common to plot the WOE1 values versus the mean values of x at bin i.
3.2. A Rule of Thumb of IV
Intuitively, the larger the IV, the more predictive the independent variable. However, if IV is too large, it should be checked for over predicting. For instance, x may be a postknowledge variable.
To quantify IV, a rule of thumb is proposed in [17, 18]:
less than 0.02: unpredictive,
0.02 to 0.1: weak,
0.1 to 0.3: medium,
0.3+: strong.
In addition, mathematical reasoning of the rule of thumb is given in [18]. In more detail, IV can be expressed as the average of 2 likelihood ratio test statistics G(P,Q) and G(Q,P) of Chi-square distributions with (n-1) degrees of freedom:
(42)2×IV=2∑i=1npiln(piqi)+2∑i=1nqiln(qipi)=G(P,Q)+G(Q,P).
The close relationship between IV and the likelihood ratio test allows using the Chi-square distribution to assign a significance level.
However, this is doubtful. On the one hand, G(P,Q) and G(Q,P) are not necessarily independent. On the other hand, even if they are independent, it is not enough. Let us assume that 2 × IV follows a Chi-square distribution with 2(n-1) degrees of freedom. Yet, the critical values of the Chi-square distribution are too large compared with the values in the rule of thumb, as can be seen from the Chi-square table in many books about Probability, say [19].
We only list the first several rows of Table 1. When Table 1 grows as DF increases, the values in each column will increase. One may use the Excel function CHIINV(p,df) or its newer and more accurate version CHISQ.INV.RT(p,df) to build Table 1, which returns the inverse of the right-tailed probability 1-p of the Chi-square distribution with df degrees of freedom.
Chi-square table.
DF
P=0.005
0.01
0.025
0.05
0.25
0.5
0.75
0.9
0.95
0.975
0.99
1
0
0
0.001
0.004
0.1
0.45
1.32
2.71
3.84
5.02
6.64
2
0.01
0.02
0.051
0.1
0.58
1.39
2.77
4.61
5.99
7.38
9.21
3
0.072
0.11
0.22
0.35
1.21
2.37
4.11
6.25
7.81
9.35
11.3
4
0.21
0.3
0.48
0.71
1.92
3.36
5.39
7.78
9.49
11.1
13.3
5
0.41
0.55
0.83
1.15
2.67
4.35
6.63
9.24
11.1
12.8
15.1
6
0.68
0.87
1.24
1.64
3.45
5.35
7.84
10.6
12.6
14.4
16.8
⋮
⋮
⋮
⋮
⋮
⋮
⋮
⋮
⋮
⋮
⋮
⋮
10
2.16
2.56
3.25
3.94
6.74
9.34
12.5
16.0
18.3
20.5
23.2
⋮
⋮
⋮
⋮
⋮
⋮
⋮
⋮
⋮
⋮
⋮
⋮
18
6.26
7.01
8.23
9.39
13.7
17.3
21.6
26.0
28.9
31.5
34.8
The critical values are as small as the values in the rule of thumb only when the degrees of freedom are as small as 6. For instance, there is a probability of 1-0.005=0.995 that a Chi-square distribution with 6 degrees of freedom will be larger than or equal to 0.68, that is,
(43)CHIINV(0.995,6)=0.68.
Yet, there is a probability of 0.995 that a Chi-square random variable with 10 degrees of freedom will be larger than or equal to 2.16. There is a probability of 0.995 that a Chi-square random variable with 18 degrees of freedom will be larger than or equal to 6.26. On the basis of the above, the rule of thumb is more or less empirical.
3.3. Calculation of IV
The calculation of IV is simple once binning is done. In this sense, IV is a subjective measure. It depends on how the binning is done and how many bins are used. Different binning methods may result in different IV values, whereas the logistic regression in the later stages will not use the information of these bins.
In practice, 10 or 20 bins are used. The more the bins, the better the chance the good accounts will be separated from the bad accounts. Yet, we cannot divide the values of x indefinitely since we may not avoid 0 good account or 0 bad account in some bins. To overcome the limitation of the logarithm function in the J-divergence, the binning should avoid 0 good account or 0 bad account in any bins.
The idea of binning is to assign values ofxwith similar behaviors to the same group or bin. In particular, the same values ofxmust fall into the same bin. A natural way of binning is to sort the data first and then divide them into n bins with an equal number of observations (the last bin may have less number of observations). This works well if x has no repeating values at all. In reality, x often has repeating values (called the tied values in statistics), which may cause problems when the tied values of x fall into different bins.
Proc Rank in SAS serves, a good candidate for binning (as opposed to function cut in R). When there are no tied values in x, it simply divides the values ofxinto n bins. When there are tied values inx, it treats the tied values by its option TIES.
Proc Rank begins with sorting the values of x within a BY group. It then assigns each nonmissing value an ordinal number that indicates its rank or position in the sequence. In case of ties, option TIES will be used. Depending on whether TIES = LOW, HIGH, or MEAN (default one), the lowest rank, highest rank, or the average rank will be assigned to all the tied values. Next, the following formula is used to calculate the binning value of each nonmissing value ofx:
(44)⌊rank×nm+1⌋,
where⌊⌋is the floor function, rank the value’s rank, nthe number of bins, and m the number of nonmissing observations. Note that the range of the binning values is from 0 to n-1. Finally, all the values of x are binned according to their binning values. In case one bin has less than 5% of the population, we may combine this bin with its neighboring bin.
To illustrate the use of Proc Rank withn=10and TIES = MEAN, let us look at an imaginary dataset with one variable age and 100 observations. Assume this dataset has been sorted and has fifty observations with a value of 10, thirty observations with a value of 20, ten observations with a value of 30, nine observations with a value of 40, and one observation with a value of 50.
The first 50 observations have a tied value of 10. Each of them will be assigned an average rank of k=25.5 and hence a binning value of ⌊(25.5×10)/101⌋=2. The next 30 observations have a tied value of 20. Each of them will be assigned an average rank of (51+52+⋯+80)/30=65.5 and hence a binning value of ⌊(65.5×10)/101⌋=6. The next 10 observations have a tied value of 30. Each of them will be assigned an average rank of (81+82+⋯+90)/10=85.5 and hence a binning value of ⌊(85.5×10)/101⌋=8. The next 9 observations have a tied value of 40. Each of them will be assigned an average rank of (91+92+⋯+99)/9=95 and hence a binning value of ⌊(95×10)/101⌋=9. The last observation has a rank of 100 and hence will be assigned a binning value of ⌊(100×10)/101⌋=9. In summary, the 100 observations are divided into 4 bins: the first 50 observations, the next 30 observations, the next 10 observations, and the last 10 observations.
Remark 15.
Missing values are not ranked and are left missing in Proc Rank. Yet, they may be kept in a separate bin by means of Proc Summary or Proc Means in the calculation of IV.
Remark 16.
If x has less thankdifferent values, the number of bins by Proc Rank will be less that k.
After binning is done for x, a simple SAS program can be written to calculate IV. Meanwhile, WOE1 are calculated per bin as for WOE in [17]. If IV is less than 0.02, we will throw this independent variable. If IV is large than 0.3, over predicting will be checked. If IV is between 0.02 and 0.3 and WOE1 are linear, we will include this independent variable as a candidate variable in logistic regression. If IV is between 0.02 and 0.3 but WOE1 are not linear, we may make transformations of the independent variable to make WOE1 more linear. If a transformation can preserve the rank of the original independent variable, the binning by Proc Rank will be preserved. Therefore, we have obtained the following result.
Proposition 17.
IV, when binning by Proc Rank, is invariant under any strictly monotonic transformations.
3.4. Mathematical Properties of IV
IV is the information statistic for the difference between the information in the good accounts and the information in the bad accounts. Indeed, IV is the J-divergence with distributions of good accounts and bad accounts. Thus, IV is lower bounded by the square ofL1(P∥Q)by Theorem 10.
Property 1.
IV≥(L1(P∥Q))2.
Property 2.
IV satisfies the inequalities (15); that is,
(45)14Δ(P∥Q)≤I(P∥Q)≤h(P∥Q)≤4d(P∥Q)≤IV8≤T(P∥Q)≤116ψ(P∥Q).
In particular, IV is upper bounded byψ(P∥Q):
(46)IV≤12∑i=1n(pi-qi)2(pi+qi)piqi.
Note that there is a direct proof of the above inequality, which is much easier than that in [14]. Let us assume without loss of generality that p1≥q1, p2≥q2,…,pk≥qk, and pk+1<qK+1,…,pn<qn.
Proof.
Using the identity pi/qi=1+((pi-qi)/q1) and making Taylor’s expansion of function ln(pi/qi) around 1 for i=1,2,…,k, we obtain
(47)ln(piqi)=ln(1)+12pi-qiqi-12(1+ξ)2(pi-qiqi)2≤12pi-qiqi.
Multiplying pi-qi≥0 and summing up from1 to k, we obtain
(48)∑i=1k(pi-qi)ln(piqi)≤12∑i=1k(pi-qi)2qi≤12∑i=1n(pi-qi)2qi.
Similarly,ln(qi/pi)≤(1/2)((qi-pi)/pi).Multiplyingqi-pi≥0and summing up from k to n, we obtain
(49)∑i=k+1n(qi-pi)ln(qipi)≤12∑i=k+1n(qi-pi)2pi≤12∑i=1n(pi-qi)2pi.
The proof is completed by noting that
(50)∑i=1n(pi-qi)ln(piqi)=∑i=1k(pi-qi)ln(piqi)+∑i=k+1n(pi-qi)ln(piqi)=∑i=1k(pi-qi)ln(piqi)+∑i=k+1n(qi-pi)ln(qipi).
Theorem 18.
IV is convex in the pair(p,q).
Proof.
Applying Theorem 2.7.2 from [15] to both D(P∥Q) and D(Q∥P), we obtain
(51)J(λP1+(1-λ)P2∥λQ1+(1-λ)Q2)=D(λP1+(1-λ)P2∥λQ1+(1-λ)Q2)+D(λQ1+(1-λ)Q2∥λP1+(1-λ)P2)≤λD(P1∥Q1)+(1-λ)D(P2∥Q2)+λD(Q1∥P1)+(1-λ)D(Q2∥P2)=λ(D(P1∥Q1)+D(Q1∥P1))+(1-λ)(D(P2∥Q2)+D(Q2∥P2))=λJ(P1∥Q1)+(1-λ)J(P2∥Q2).
Remark 19.
J(P∥Q) is not convex albeit a metric.
Property 3.
If more than 95% of population ofxhave the same value, then IV = 0. In particular, ifxhas just one value, then IV = 0.
Proof.
Assume more than 95% of population of x have the same valuex0. Then, all the population with valuex0will fall into the same bin, called the majority bin. The rest of population whose values are different fromx0will be combined into the majority bin. Thus, there will be only one bin for all the values ofx.Therefore g1=g, b1=b, and hence IV = 0.
Remark 20.
If the population whose values are notx0are not combined into the majority bin, then IV could be larger than 0.02. As shown in Table 2,xhas 10000 observations, where 95.8% or 9580 observations have the same value, say 2, and the rest of 420 observations have another value, say 4. Both bins contribute a value larger than 0.02 to IV. Statistically, 4.2% of the population are outliers and can be neglected. Hence, it is more meaningful to sayxhas no information toy.
Outlier domination to IV.
Bin
Count
Goods
Distr. good
Bads
Distr. bad
IV contr.
1
9580
7600
99.74%
1980
83.19%
0.03001
2
420
20
0.26%
400
16.81%
0.68814
Total
10000
7620
100.00%
2380
100.00%
0.71815
3.5. Alternatives to IV
As we have seen above, IV has 3 shortcomings: (1) it is not a metric; (2) no groups are allowed to have 0 bad accounts or 0 good accounts; and (3) its range is too broad, from 0 to∞.
Theoretically, any divergence measures of the difference or distance between good distributions and bad distributions can be alternatives to IV. In particular,Lp(P∥Q)(p≥1) are good alternatives to IV. They overcome all the 3 shortcomings of IV: (1)Lp(P∥Q)are all metrics; (2) they allow bins to have 0 bad accounts or 0 good accounts; and (3) They all have a much narrow range, from 0 to 2.
WhileLP(P∥Q)do not seem to have a tie with weight of evidence, they can be as quantifiable as IV. For instance, we may adopt a rule of thumb forLP(P∥Q):
weak: 6% of its upper bound,
medium: 6% to 30% of its upper bound,
strong: Larger than 30% of its upper bound.
In particular,
weak: 0.12 for L1(P∥Q), 0.085 for L2(P∥Q), and 0.06 for L∞(P∥Q),
medium: 0.12 to 0.60 for L1(P∥Q), 0.085 to 0.424 for L2(P∥Q), and 0.06 to 0.30 forL∞(P∥Q),
The lower bound 0.12 of L1(P∥Q) can be adjusted as needed. It can also be combined with IV to enhance the accuracy. For instance, for the number of independent variables is large enough, we may select only those which satisfy both lower bounds of L1(P∥Q) and IV.
4. Numerical Results
To illustrate our results, we use Exhibit 6.2 in [17] but add one column for WOE1. We use the real WOE, not its “more user-friendly” form—100 times WOE.
From Table 3, we see that L∞<L2<L1<IV. From Figure 1, we also see that the WOE1 for nonmissing values has a linear trend for variable age.
Calculation of IV and WOE.
Age
Count
Tot. distr.
Goods
Distr. good
Bads
Distr. bad
WOE
WOE1
Missing
1000
2.5%
860
2.38%
140
3.65%
−0.42719
4.117875
18–22
4000
10%
3040
8.41%
960
25%
−0.10898
1.15268
23–26
6000
15%
4920
13.61%
1080
28.13
−0.72613
1.516347
27–29
9000
22.5%
8100
22.4%
900
23.44%
−0.04526
2.197225
30–35
10000
25%
9500
26.27%
500
13.02%
0.70196
2.944439
35–44
7000
17.5%
6800
18.81%
200
5.21%
1.28388
3.526361
44+
3000
7.5%
2940
8.13%
60
1.56%
1.64934
3.89182
Total
40000
100%
36160
100%
3840
100%
IV=0.6681, and IV=0.8174.
L_{1} = 0.6684, L_{2} = 0.2987, and L_{∞} = 0.1659.
Logical Trend of WOE1 for Variable Age.
5. Conclusions
In this paper, we have proposed a class of metric divergence measures, namely, Lp(P∥Q), p≥1, and studied their mathematical properties. We studied information value, an important divergence measure widely used in credit scoring. After exploring the mathematical reasoning of a rule of thumb and weight of evidence, we suggested an alternative to weight of evidence. Finally, we proposed using Lp(P∥Q) as alternatives to information value to overcome its disadvantages.
TanejaI. J.Generalized relative information and information inequalitiesHellingerE.Neue begründung der theorie der quadratischen formen von unendlichen vielen veränderlichenShannonC. E.A mathematical theory of communicationKullbackS.LeiblerR. A.On information and sufficiencyJeffreysH.An invariant form for the prior probability in estimation problemsTopsøeF.Some inequalities for information divergence and related measures of discriminationDragomirS. S.ŠundeJ.BuşeC.New inequalities for Jeffreys divergence measurePearsonK.On the criterion that a given system of deviations from the probable in the case of correlated system of variables is such that it can be reasonable supposed to have arisen from random samplingSibsonR.Information radiusBurbeaJ.RaoC. R.Entropy differential metric, distance and divergence measures in probability spaces: a unified approachBurbeaJ.RaoC. R.On the convexity of some divergence measures based on entropy functionsTanejaI. J.HawkesP. W.New developments in generalized information measuresCressieN.ReadT. R. C.Multinomial goodness-of-fit testsTanejaI. J.Generalized Symmetric Divergence Measures and InequalitiesCoverT. M.ThomasJ. A.da CostaG. A. T. F.TANEJAI. J.SiddiqiN.SiddiqiN.DowningD.ClarkJ.