%% Obtain Information for a Specified PredictorName After Using fillmissing
% Create a creditscorecard object using the CreditCardData.mat file to load the data (using a dataset from Refaat 2011).

load CreditCardData
sc = creditscorecard(dataMissing,'BinMissingData',true,'IDVar','CustID');
sc = autobinning(sc);

%
% Use fillmissing to replace missing values for the CustAge predictor with a value of 38.

sc = fillmissing(sc,'CustAge','constant',38);

% Obtain the predictor statistics for the PredictorName of CustAge.

[T,Stats] = predictorinfo(sc,'CustAge')

%
% Use fillmissing to replace missing values for the ResStatus predictor with a mode value.

sc = fillmissing(sc,'ResStatus','mode');

% Obtain the predictor statistics for the PredictorName of ResStatus.

[T,Stats] = predictorinfo(sc,'ResStatus')

% Copyright 2019 The MathWorks, Inc.