Created
May 18, 2020 17:18
-
-
Save AjayThorve/f63f8afa2713713b0fe2c3b8df311501 to your computer and use it in GitHub Desktop.
cuxfilter eg. 2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import cuxfilter | |
import cudf | |
df = cudf.read_parquet('./data/census_data.parquet/*') | |
#create cuxfilter dataframe | |
cux_df = cuxfilter.DataFrame.from_dataframe(df) | |
#declare charts | |
chart0 = cuxfilter.charts.scatter_geo(x='x', y='y') | |
chart1 = cuxfilter.charts.bar('age') | |
chart2 = cuxfilter.charts.bar('sex') | |
chart3 = cuxfilter.charts.bar('cow') | |
chart4 = cuxfilter.charts.bar('income') | |
chart5 = cuxfilter.charts.bar('education') | |
d = cux_df.dashboard( | |
[chart0, chart1, chart2, chart3, chart4, chart5], | |
layout=cuxfilter.layouts.feature_and_five_edge, | |
) | |
d.show() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment