Part 2 – Creating the USFlightsAnalysis PixieApp
For the first iteration of our USFlightsAnalysis
, we want to implement a simple user story that leverages the analytics created in Part 1:
The welcome screen will show two drop-down controls for selecting an origin and a destination airport
When an airport is selected, we show a graph showing the selected airports and its immediate neighbors
When both airports are selected, the user clicks on the Analyze button to show a Mapbox map with all the airports
The user can select one of the centrality indices available as checkboxes to show the shortest flight path according to the selected centrality
Let's first look at the implementation for the welcome screen which is implemented in the default route of the USFlightsAnalysis
PixieApp. The following code defines the USFlightsAnalysis
class which is decorated with the @PixieApp
decorator to make it a PixieApp. It contains a main_screen()
method that is decorated with the @route()
decorator to make it...