#!/usr/bin/env python # coding: utf-8 #
#

Are Hollister CA Homes Increasing in Value or Decreasing in Value?

#
# #
# #
# Mikaela Rojas | Rojas Realty #
# #
# #
# #
#

Hello!

#

I’m Mikaela Rojas!


#
#
# Thank you for choosing me as your South Bay Realtor! Let's take a
# a look at Hollister CA home values. #
# #
# #
# In[1]: import pandas as pd import matplotlib.pyplot as plt # only needed for advanced plotting import matplotlib.dates as dates plt.style.use('ggplot') get_ipython().run_line_magic('matplotlib', 'inline') # In[2]: # grab Zillow data # Hollister,CA,San Jose,San Benito|00800 # FR = Percentage of Sales that were Foreclosures df_iv = pd.read_csv('http://www.quandl.com/api/v3/datasets/ZILL/C00800_IV.csv') df_dv = pd.read_csv('http://www.quandl.com/api/v3/datasets/ZILL/C00800_DV.csv') df_dv.head(); # In[3]: # convert to date format df_iv['Date'] = pd.to_datetime(df_iv['Date']) df_dv['Date'] = pd.to_datetime(df_dv['Date']) # In[4]: # rename columns df_iv.columns = ['Date','num_increasing'] df_dv.columns = ['Date','num_decreasing'] # In[5]: # set Date to be the index df_iv = df_iv.set_index('Date') df_dv = df_dv.set_index('Date') # ## Good News for Buyers! Homes in general have been decreasing in value since 2016. # In[6]: # Advanced Plotting #################### fig, axes = plt.subplots(nrows=1, ncols=1, figsize=(13, 5)) fig.subplots_adjust(hspace=1.0) ## Create space between plots # Chart 1 mask1 = df_iv.index.year >= 2016 df_iv[mask1].sort_index().plot.line(ax=axes) # Chart 2 mask1 = df_dv.index.year >= 2016 df_dv[mask1].sort_index().plot.line(ax=axes, alpha=0.4, color='b') # add a little sugar axes.set_title('Number of Home Increasing or Decreasing in Value') axes.set_ylabel('# of homes') axes.legend(["# increasing","# decreasing"], loc='best'); #

Hollister CA Realtor: ROJAS REALTY

# #
#

the information came from quandl and Zillow

#
# In[7]: from IPython.display import HTML HTML('''
''')