<jupyter_start><jupyter_text>Lambda School Data Science*Unit 2, Sprint 3, Module 4*--- Model Interpretation- Visualize and interpret **partial dependence plots**- Explain individual predictions with **shapley value plots** I. Wrangle Data<jupyter_code>import pandas as pd<jupyter_output><empty_output><jupyter_text>II. Split Data<jupyter_code><jupyter_output><empty_output><jupyter_text>III. Establish Baseline<jupyter_code><jupyter_output><empty_output><jupyter_text>IV. Build Model<jupyter_code>from sklearn.linear_model import Ridge
from sklearn.ensemble import RandomForestRegressor
from xgboost import XGBRegressor<jupyter_output><empty_output><jupyter_text>V. Check Metrics<jupyter_code><jupyter_output><empty_output><jupyter_text>VI. Communicate Results Partial Dependence PlotsOne Feature<jupyter_code><jupyter_output><empty_output><jupyter_text>Two features<jupyter_code><jupyter_output><empty_output><jupyter_text>Shapley Plots- Show you the influence of features in *individual* predictions.<jupyter_code>import shap<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.08987701040681173, 'fraction_numerical': 0.002838221381267739, 'mean_word_length': 11.902439024390244, 'pattern_counts': {'":': 0, '<': 33, '<?xml version=': 0, '>': 33, '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': '8', 'dir': 'jupyter-structured-clean-dedup', 'id': '584816', 'license': 'MIT', 'n_tokens_mistral': 370, 'n_tokens_neox': 354, 'n_words': 67, 'path': 'module4-model-interpretation/234_guided_project_notes.ipynb', 'repo_name': 'ryanleeallred/DS-Unit-2-Applied-Modeling', 'size': '1057'}