<jupyter_start><jupyter_text>Making a neater format for `COHORT`<jupyter_code>dfchurn['COHORT'] = dfchurn['COHORT'].replace({'FTF_2108':'2010', 'FTF_2118':'2011', 'FTF_2128':'2012', 'FTF_2138':'2013', 'FTF_2148':'2014'})
dfchurn['COHORT'].unique()
for col in dfchurn.columns[2:9]:
    print(col,dfchurn[col].unique())<jupyter_output>NATIVE_COLLEGE ['BUS' 'LA' 'ENG' 'SM' 'AGR' 'DES']
GENDER ['F' 'M' nan]
ETHNICITY ['WHITE' 'HISPA' 'ASIAN' 'TWOMORE' 'DECLINE' 'BLACK' 'AMIND' nan]
RESIDENCY ['Resident' 'Non Res' 'Foreign Co']
AOA_RSNCODE ['Mand' 'Acad' 'Other' 'Early' 'Adm']
MothersEd [ 6.  7.  4.  5.  3. nan  1.  2.]
FathersEd [ 6.  5.  7.  4.  1. nan  3.  2.]<jupyter_text>Above columns look good.<jupyter_code>dfchurn['HS_GPA'].plot.hist()
dfchurn.loc[dfchurn['HS_GPA'].isnull()].head()<jupyter_output><empty_output><jupyter_text>The `HS_GPA` column has missing values and values with 0s. We will work with the assumption that 0s have some meaning and create an indicator variable.<jupyter_code>dfchurn.PARTNER_SCHOOL.unique()
dfchurn.SATRead.plot.hist()
dfchurn.SATMath.plot.hist()
from matplotlib import pyplot as plt
plt.bar(dfchurn.Churn.unique(),dfchurn.Churn.value_counts()/len(dfchurn.Churn))
plt.xticks(np.array([0,1]))
dfchurn.COHORT.unique()
dfchurn.to_csv('10_14_Churn.csv')<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.1801665404996215, 'fraction_numerical': 0.04844814534443603, 'mean_word_length': 6.641618497109826, 'pattern_counts': {'":': 0, '<': 12, '<?xml version=': 0, '>': 12, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '3', 'dir': 'jupyter-structured-clean-dedup', 'id': '123165', 'license': 'MIT', 'n_tokens_mistral': 619, 'n_tokens_neox': 571, 'n_words': 107, 'path': 'Jupyter_Notebooks/data-cleaning.ipynb', 'repo_name': 'clazaro97chosen/CSU_CostBenefit_Analysis', 'size': '1321'}