smbinning.logitrank: Logistic Regression Ranking

Description Usage Arguments Value Examples

View source: R/smbinning.R

Description

It runs all the possible logistic models for a given set of characteristics (chr) and then rank them from highest to lowest performance based on AIC. Important Note: This function may take time depending on the datset size and number of variables used in it. The user should run it at the end of the modeling process once variables have been pre-selected in previous steps.

Usage

1

Arguments

y

Binary dependent variable.

chr

Vector with the characteristics (independent variables).

df

Data frame.

Value

The command smbinning.logitrank returns a table with the combination of characteristics and their corresponding AIC and deviance. The table is ordered by AIC from lowest (best) to highest.

Examples

1
2
3
4
5
# Load library and its dataset
library(smbinning) # Load package and its data

# Example: Best combination of characteristics
smbinning.logitrank(y="fgood",chr=c("chr1","chr2","chr3"),df=smbsimdf3)

Example output

Loading required package: sqldf
Loading required package: gsubfn
Loading required package: proto
Loading required package: RSQLite
Loading required package: partykit
Loading required package: grid
Loading required package: libcoin
Loading required package: mvtnorm
Loading required package: Formula
Warning message:
no DISPLAY variable so Tk is not available 
  Characteristics      AIC Deviance
7       chr1+chr2 1050.973 1044.973
8  chr1+chr2+chr3 1052.116 1044.116
3            chr2 1150.986 1146.986
5       chr2+chr3 1152.952 1146.952
6       chr1+chr3 1185.607 1179.607
4            chr1 1191.942 1187.942
2            chr3 1208.601 1204.601
1  Intercept Only 1209.866 1207.866

smbinning documentation built on May 1, 2019, 10:06 p.m.