from cuxfilter import charts
import cuxfilter
from bokeh import palettes
cux_df = cuxfilter.DataFrame.from_arrow('./data/146M_predictions_v2.arrow')
geoJSONSource='https://raw.githubusercontent.com/rapidsai/cuxfilter/GTC-2018-mortgage-visualization/javascript/demos/GTC%20demo/src/data/zip3-ms-rhs-lessprops.json'
charts_list = [
cuxfilter.charts.choropleth( x='zip', color_column='delinquency_12_prediction', color_aggregate_fn='mean',
elevation_column='current_actual_upb', elevation_factor=0.00001, elevation_aggregate_fn='sum',
geoJSONSource=geoJSONSource, data_points=1000, tooltip_include_cols=['zip', 'current_actual_upb']),
cuxfilter.charts.bar('delinquency_12_prediction',data_points=50)
]
sidebar_list = [cuxfilter.charts.range_slider('borrower_credit_score',data_points=50), cuxfilter.charts.drop_down('dti')]