<jupyter_start><jupyter_text>Create the Issues Data for Integration<jupyter_code>supreme_court_df.adminAction
supreme_court_df = supreme_court_df[~supreme_court_df['usCite'].isna()].copy()
supreme_court_df.usCite = supreme_court_df.usCite.apply(lambda x: x.replace('.', ""))

supreme_court_df.usCite
supreme_court_df.issueArea<jupyter_output><empty_output><jupyter_text>Upon ReviewIt is unnecessary to integrate this data. I have these and more. The hierarchal nature limits the validity of the reading.    Preparing the Justice Data<jupyter_code>supreme_court_df.justiceName.unique()<jupyter_output><empty_output><jupyter_text>The Supreme Court Justices Data<jupyter_code>## Importing our DataFrames

filepath = "/Users/jnapolitano/Projects/supreme_court_db_integration/data/justices.csv"


justice_df = pd.read_csv(filepath)

justice_df
new_justice_df = pd.DataFrame()
new_justice_df['justice_name'] = justice_df['Justice Name']
new_justice_df['term_start'] = justice_df['Supreme Court Term Start']
new_justice_df['term_end'] = justice_df['Supreme Court Term End']
new_justice_df['appointee'] = justice_df['Appointing President']
### remove -- 

new_justice_df.term_start = new_justice_df.term_start.mask(new_justice_df.term_start == '--', np.nan)
new_justice_df.term_end = new_justice_df.term_end.mask(new_justice_df.term_end == '--', np.nan)

new_justice_df



outfile = "/Users/jnapolitano/Projects/supreme_court_db_integration/data/formatted_justices.csv"
new_justice_df.to_csv(outfile)<jupyter_output><empty_output><jupyter_text>Cases Table<jupyter_code>filepath = "/Users/jnapolitano/Projects/supreme_court_db_integration/data/Table of Cases  Resources  Constitution Annotated  Congress.gov  Library of Congress.csv"

## Importing our DataFrames

cases_df = pd.read_csv(filepath)
cases_df
test = cases_df['Constitution Annotated'].unique()
test['']
filepath = "/Users/jnapolitano/Projects/supreme_court_db_integration/data/Table of Laws Held Unconstitutional in Whole or in Part by the Supreme Court  Resources  Constitution Annotated  Congress.gov  Library of Congress.csv"

test = pd.read_csv(filepath)
test<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.10340009315323707, 'fraction_numerical': 0.0, 'mean_word_length': 7.839506172839506, 'pattern_counts': {'":': 0, '<': 17, '<?xml version=': 0, '>': 17, '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': '4', 'dir': 'jupyter-structured-clean-dedup', 'id': '416697', 'license': 'Apache-2.0', 'n_tokens_mistral': 780, 'n_tokens_neox': 752, 'n_words': 126, 'path': 'active_code_base/neo4jAPI/data_exploration.ipynb', 'repo_name': 'justin-napolitano/USSupremeCourtMetaDataGraph', 'size': '2147'}