In [54]:
import os
import settings
import pandas as pd
In [55]:
writer = pd.ExcelWriter(
os.path.join(settings.data_dir, '2016-analysis.xlsx'),
engine='xlsxwriter'
)
In [56]:
props = settings.open_csv('props-2016.csv')
In [57]:
props.to_excel(writer, sheet_name="Propositions", index=False)
In [58]:
committees = settings.open_csv('committees-2016.csv')
In [59]:
committees.to_excel(writer, sheet_name="Committees", index=False)
In [60]:
committee_positions = settings.open_csv("committees-and-props-2016.csv")
In [61]:
committee_positions.to_excel(writer, sheet_name="Committee positions", index=False)
In [62]:
filings = settings.open_csv("filings-2016.csv")
In [63]:
filings.to_excel(writer, sheet_name="Filings (Since 2015-01-01)", index=False)
In [64]:
transfers = settings.open_csv("transfers-2016.csv")
In [65]:
transfers.to_excel(writer, sheet_name="Tranfers (Schedule D)", index=False)
In [66]:
refunds = settings.open_csv("refunds-2016.csv")
In [67]:
refunds.to_excel(writer, sheet_name="Refunds (Schedule E)", index=False)
In [68]:
writer.save()