PerspectiveExamples

X/Y Scatter - Category Y Axis And Size And Color — Colored Bubble plot. X is State. Y is product sub-category. Size is Sales. Color is Quantity.

X/Y Scatter chart of State, Sub-Category, Quantity and Sales, grouped by State and Sub-Category.

X/Y Scatter - Category Y Axis And Size And Color — Colored Bubble plot. X is State. Y is product sub-category. Size is Sales. Color is Quantity.: X/Y Scatter chart of State, Sub-Category, Quantity and Sales, grouped by State and Sub-Category.

Data

Programmatic variations on the Superstore retail sales dataset, showing the flexibility of Perspective's configuration: the same table re-queried as data grids, pivot tables and charts by changing only the viewer's JSON config.

Loaded from /data/superstore.lz4.arrow as arrow into the perspective-server engine.

Configuration

This example is a saved <perspective-viewer> workspace. Pass this JSON to viewer.restoreWorkspace() to reproduce it over the same table:

{
    "layout": {
        "type": "tab-layout",
        "tabs": [
            "p0"
        ],
        "selected": 0
    },
    "panels": {
        "p0": {
            "table": "",
            "title": "X/Y Scatter - Category Y Axis And Size And Color",
            "plugin": "X/Y Scatter",
            "columns": [
                "State",
                "Sub-Category",
                "Quantity",
                "Sales",
                null
            ],
            "group_by": [
                "State",
                "Sub-Category"
            ],
            "aggregates": {
                "State": "dominant",
                "Sub-Category": "dominant",
                "Profit": "low"
            },
            "theme": null
        }
    },
    "active": "p0"
}

About Perspective

Perspective is an open-source, WebAssembly-powered data grid, pivot table and charting component for large, real-time and streaming datasets — in the browser, Python, Jupyter, Node.js and Rust.

Documentation