Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
PySAL Visualization Project
This document will guide the development effort for the PySAL visualization layer. Currently residing in contrib, the goal of the layer is to provide simple (use- and dependency-wise) and lightweight conversion of PySAL structures into commonly used visualizations. The main use-cases that inspired and guide the development of the layer are:
- "Interactive" data exploration (many static but easy plots that allow you to quickly iterate over ideas until finding the right one)
- (Publication-ready) static plots
Design and Components
The layer is composed of three main levels, each with a specific function in mind:
Matplotlibgeometries. This is mostly implemented already.
Mid-level: utilities where most of the
PySALfunctionality is implemented and applied to
Matplotlibobjects. This includes: subsetting (e.g. plot only part of a .shp), aligning (e.g. same axes for different layers) and transforming (e.g. classify values to colors) graphical objects. All the new functionality required to create the end-user views described below will live here.
High-level: end-user utilities that wrap generic functionality from the mid-level into specific views that visualize output from
PySALmethods and classes.
This structure combines simplicity and ease of use, implemented in the end-user functions, with a great deal of flexibility implemented in the mid-level (just as in generic Matplotlib, if you know what you're doing, the sky is the limit).
- Join Count (BW)
- Regression maps:
- fit & observed paired view
- Indirect/Direct Effects map (sum of diagonal/off diagonal of filter matrix)
- Scatter Plots
- Space-Time LISA
- Bivariate LISA
- Pairwise regression plots
- Four-plot statistical summary for regression
- residual vs. fit
- standard residual vs. fit
- Residuals vs. leverage (if leverage is available)
- Observed vs. simulated envelopes (e.g. King Tomz, and Wittenberg(2002), (KTW))
- Simulated differences in expected densities given change in conditions (KTW Fig. 2)
- marginal densities for scatterplots
- Direct/Indirect effect densities
- Lorenz Curve (GINI)
- Rank Paths (graphs/networks)
- Trajectory Paths
- Rose Diagram
- Directional LISA
- Time series (spatial dynamics)
- Point Patterns
- slider for weights explorer
- slider for distance weights
Our plan is to proceed in three stages.
- Prototype examples of a select view views using matplotlib
- Refine our design of these views based on prototype experience
- Design an API that could support use of PySAL with other visualization toolkits (i.e., D3, Bokeh, follium, future ipython Notebook interactivity).