<jupyter_start><jupyter_text>IST 718 LAB 6<jupyter_code># !pip install fbprophet
%matplotlib inline
import pandas as pd
from fbprophet import Prophet

import matplotlib.pyplot as plt
plt.style.use('fivethirtyeight')
df = pd.read_csv('https://raw.githubusercontent.com/danielcaraway/data/master/Zip_Zhvi_SingleFamilyResidence.csv', encoding='latin')<jupyter_output><empty_output><jupyter_text>PART ONE: Arkansas Metro Areas<jupyter_code>hs = df[df['Metro'].str.contains('Hot Springs', na=False)]
lr = df[df['Metro'].str.contains('Little Rock', na=False)]
f = df[df['Metro'].str.contains('Fayetteville', na=False)]
s = df[df['Metro'].str.contains('Searcy', na=False)]
def graph_prices_for(df, location_name):
  df_t = df.loc[:, '1996-04'::].T
  df_t['avg'] = df_t.mean(numeric_only=True, axis=1)
  df_t.reset_index(inplace=True)
  columns = ['index', 'avg']
  df = pd.DataFrame(df_t, columns = columns)
  df = df.rename(index=str, columns={"avg": "y", "index": "ds"})
  ax = df.set_index('ds').plot(figsize=(12, 8))
  ax.set_ylabel('Home Prices in ' + location_name)
  ax.set_xlabel('Date')
  plt.show()
graph_prices_for(hs, "Hot Springs")
graph_prices_for(lr, "Little Rock")
graph_prices_for(f, "Fayetteville")
graph_prices_for(s, "Searcy")<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.17415287628053586, 'fraction_numerical': 0.01103230890464933, 'mean_word_length': 7.355263157894737, 'pattern_counts': {'":': 2, '<': 9, '<?xml version=': 0, '>': 9, 'https://': 1, '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': '2', 'dir': 'jupyter-structured-clean-dedup', 'id': '372987', 'license': 'MIT', 'n_tokens_mistral': 518, 'n_tokens_neox': 498, 'n_words': 84, 'path': 'assets/ist718lab6/code/og/IST718_LAB6.ipynb', 'repo_name': 'dskw1/dskw1.github.io', 'size': '1269'}