<jupyter_start><jupyter_text>The logistic regression model fit to the full dataset is overfitting the training data. That is, the noisy parameters confuse it.<jupyter_code>clf = LogisticRegression()
clf.fit(X_selected_train_scaled, y_train)
print(f'Training Score: {clf.score(X_selected_train_scaled, y_train)}')
print(f'Testing Score: {clf.score(X_selected_test_scaled, y_test)}')<jupyter_output>Training Score: 0.9066666666666666
Testing Score: 0.84
{'fraction_non_alphanumeric': 0.0975609756097561, 'fraction_numerical': 0.04434589800443459, 'mean_word_length': 9.044444444444444, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 4, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 1, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '73146', 'license': 'ADSL', 'n_tokens_mistral': 177, 'n_tokens_neox': 155, 'n_words': 37, 'path': '01-Lesson-Plans/19-Supervised-Machine-Learning/3/Activities/04-Ins_Forest-Features/Solved/RandomForest-Feature-Selection.ipynb', 'repo_name': 'anirudhmungre/sneaky-lessons', 'size': '451'}