Engaging plots, made easy.

Easily turn your data into engaging visualizations. Powerful API for coders. Powerful app for everyone.

main.py
notebook.ipynb
main.rs
from plotapi import Chord

Chord(matrix, names).show()

Visualizations Line Fight

Temporal format

Temporal formats can be used for order values and presentation.


Sample data

Let's import PlotAPI and load our sample data.

from plotapi import LineFight

samples = [
    {"order": 2000.01, "name": "Sankey", "value": 10},
    {"order": 2000.01, "name": "Terminus", "value": 10},
    {"order": 2000.01, "name": "Chord", "value": 40},
    {"order": 2000.01, "name": "Bar Fight", "value": 90},
    {"order": 2000.01, "name": "Pie Fight", "value": 70},

    {"order": 2000.02, "name": "Sankey", "value": 30},
    {"order": 2000.02, "name": "Terminus", "value": 20},
    {"order": 2000.02, "name": "Chord", "value": 40},
    {"order": 2000.02, "name": "Bar Fight", "value": 120},
    {"order": 2000.02, "name": "Pie Fight", "value": 55},

    {"order": 2000.03, "name": "Sankey", "value": 35},
    {"order": 2000.03, "name": "Terminus", "value": 45},
    {"order": 2000.03, "name": "Chord", "value": 60},
    {"order": 2000.03, "name": "Bar Fight", "value": 85},
    {"order": 2000.03, "name": "Pie Fight", "value": 100},

    {"order": 2000.04, "name": "Sankey", "value": 25},
    {"order": 2000.04, "name": "Terminus", "value": 60},
    {"order": 2000.04, "name": "Chord", "value": 90},
    {"order": 2000.04, "name": "Bar Fight", "value": 50},
    {"order": 2000.04, "name": "Pie Fight", "value": 105},

    {"order": 2000.05, "name": "Sankey", "value": 60},
    {"order": 2000.05, "name": "Terminus", "value": 80},
    {"order": 2000.05, "name": "Chord", "value": 120},
    {"order": 2000.05, "name": "Bar Fight", "value": 30},
    {"order": 2000.05, "name": "Pie Fight", "value": 95},
]

Demonstration

We can see the order values have the format YYYY.MM above. We can format the orders with format_current_order.

LineFight(samples, format_current_order="0.2f").show()
Previous
Line Fight