churn_library.py
def classification_report_image(lrc,
                                cv_rfc,
                                y_train,
                                x_test,
                                y_test,
                                y_train_preds_lr,
                                y_train_preds_rf,
                                y_test_preds_lr,
                                y_test_preds_rf):
    '''
    produces classification report for training and testing results and stores
        report as image in images folder

    input:
        y_train: training response values
        x_test: test data
        y_test: test response values
        y_train_preds_lr: training predictions from logistic regression
        y_train_preds_rf: training predictions from random forest
        y_test_preds_lr: test predictions from logistic regression
        y_test_preds_rf: test predictions from random forest

    output:
        None
    '''
    generate_report('Random Forest',
                    y_train, y_test,
                    y_train_preds_rf, y_test_preds_rf,
                    output_path='images/results/rf_results.png')

    generate_report('Logistic Regression',
                    y_train, y_test,
                    y_train_preds_lr, y_test_preds_lr,
                    output_path='images/results/logistic_results.png')

    generate_roc_curve(lrc, cv_rfc, x_test, y_test,
                       output_path='images/results/roc_curve_result.png')

    produces classification report for training and testing results and stores
        report as image in images folder

    input:
        y_train: training response values
        x_test: test data
        y_test: test response values
        y_train_preds_lr: training predictions from logistic regression
        y_train_preds_rf: training predictions from random forest
        y_test_preds_lr: test predictions from logistic regression
        y_test_preds_rf: test predictions from random forest

    output:
        None
    
produces classification report for training and testing results and stores
report as image in images folder



None
produces classification report for training and testing results and stores report as image in images folder None
def classification_report_image(lrc,
                                cv_rfc,
                                y_train,
                                x_test,
                                y_test,
                                y_train_preds_lr,
                                y_train_preds_rf,
                                y_test_preds_lr,
                                y_test_preds_rf):
    generate_report('Random Forest',
                    y_train, y_test,
                    y_train_preds_rf, y_test_preds_rf,
                    output_path='images/results/rf_results.png')
    generate_report('Logistic Regression',
                    y_train, y_test,
                    y_train_preds_lr, y_test_preds_lr,
                    output_path='images/results/logistic_results.png')
    generate_roc_curve(lrc, cv_rfc, x_test, y_test,
                       output_path='images/results/roc_curve_result.png')
def classification_report_image ( lrc , cv_rfc , y_train , x_test , y_test , y_train_preds_lr , y_train_preds_rf , y_test_preds_lr , y_test_preds_rf ) : generate_report ( 'Random Forest' , y_train , y_test , y_train_preds_rf , y_test_preds_rf , output_path = 'images/results/rf_results.png' ) generate_report ( 'Logistic Regression' , y_train , y_test , y_train_preds_lr , y_test_preds_lr , output_path = 'images/results/logistic_results.png' ) generate_roc_curve ( lrc , cv_rfc , x_test , y_test , output_path = 'images/results/roc_curve_result.png' )
produces classification report for training and testing results and stores
report as image in images folder
produces classification report for training and testing results and stores report as image in images folder
'''
    produces classification report for training and testing results and stores
        report as image in images folder

    input:
        y_train: training response values
        x_test: test data
        y_test: test response values
        y_train_preds_lr: training predictions from logistic regression
        y_train_preds_rf: training predictions from random forest
        y_test_preds_lr: test predictions from logistic regression
        y_test_preds_rf: test predictions from random forest

    output:
        None
    '''
lrc
cv_rfc
y_train
x_test
y_test
y_train_preds_lr
y_train_preds_rf
y_test_preds_lr
y_test_preds_rf