-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Finished dashboard concept #51
Finished dashboard concept #51
Conversation
…ashboard' into create-initial-concept-of-dashboard
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good
I did approve it, but I have one request, could you maybe put a README.md file in citizenvoice/dashboard with the routes that are being used. And please add in the PR comment on how to test it. E.g “Go to this route”, “Try this button” etc. Also, did it not come with any .env variables by any chance? |
Description of changes
What?
This PR concerns the development of the dashboard concept. This concept was built using "dummy data" and serves to act as a guide for the development of the actual dashboard's architecture.
The dashboard logic is spread into 3 parts: 1) Data processing, 2) Graph generation and 3) Dashboard app
a) 'data_cleaner.py' : contains the 'Cleaner' class. Eventually, this class will be filled with generic methods containing kwargs/args to allow the user to define custom cleaning rules. 'drop_columns(...)' is an example.
b) 'data_parser.py': contains the 'Parser' class. A Parser prepares the provided data in order for graph generation to be as seamless as possible. Eventually, this class will also contain generic functions to give the user an interface to implement their own parsing rules.
Graph generation: logic is encapsulated in the 'graph_utils' directory:
a) 'graph_generator.py': contains the 'Generator' class. This class will contain a variety of methods to generate different types of graphs and charts. These are created using the plotly library. However, we can look to expand this by using other libraries in the future. The method 'create_choropleth(...)' is given as an example.
Dashboard app: logic is encapsulated in the 'app' directory:
a) 'dashboard.py': contains logic for the front-end using the Dash framework. User input is accepted -> passed through the aforementioned architecture -> outputs a graph. As an example, the population evolution of London's boroughs is used as the data was easily available.
Why?
Dependencies