Nine supported chart types across eleven working examples, plus previews for Year, axes, View, Observations and Display. Every SVG comes from the shared G-Cubed exporter and synthetic projections CSV.
The CSV is the complete reloadable wide projections source. Per-chart CSV exports from a report are long-form views for analysis; they are not replacements for this source file.
Chart chooser
Rendered examples
Use each Preview selector to compare exporter-rendered states offline. The YAML beneath a card is its authored initial state; import the complete YAML and CSV into a report to use the actual report controls, table and exports.
Default line
Illustrative activity paths
Synthetic regional activity paths use complete annual observations; real gaps remain gaps.
QuestionWhere are high, low, or missing values across regions and time?
DataOne prefix varying by one model dimension and year.
UnitsOne colour scale; keep every cell in the same unit.
Preview Axes moves Year between X and Y. Year remains visible on an axis in both states, so this view has no separate Year control. Missing cells stay blank.
Complete working YAML
- chartpack:
format: gcubed-chartpack
version: 1.4.0
title: Activity by region and year
sector_selection_dimensions:
- sectors
- layers
defaults:
start_year: 2025
end_year: 2035
- chart:
title: Activity by region and year
chart_type: heatmap
show_labels: true
x_dimension: year
y_dimension: regions
x_axis:
label: Year
y_axis:
label: Region
color_axis:
min: 95
max: 115
midpoint: 100
palette: semantic-diverging
caption: A semantic diverging palette anchors the authored midpoint; a time-axis heatmap has no Year control.
series:
- variable_prefix: SYNTHINDEX
selectors:
regions: all
QuestionHow does one measure vary across two model dimensions in one year?
DataA complete or intentionally sparse region × sector grid plus chart-level year.
UnitsUS$ billion at 2025 prices; both axes use catalogue dimension keys.
year_selector exposes only eligible years. Group complete adjacent heatmaps with view_group/view_label in a full report; this per-card YAML stays independently importable.
Complete working YAML
- chartpack:
format: gcubed-chartpack
version: 1.4.0
title: Sector output by region in 2030
sector_selection_dimensions:
- sectors
- layers
defaults:
start_year: 2025
end_year: 2035
- chart:
title: Sector output by region in 2030
chart_type: heatmap
show_labels: true
x_dimension: regions
y_dimension: sectors
x_axis:
label: Region
y_axis:
label: Sector
year: 2030
year_selector: true
color_axis:
min: 0
palette: semantic-sequential
caption: Two model dimensions form a matrix; the report Year control retains the authored measure and bounds.
series:
- variable_prefix: SYNTHSECTOR
selectors:
sectors: all
regions: all
QuestionHow do many related time paths compare without one crowded plot?
DataOne facet dimension, optional group dimension, common prefix and units.
UnitsUS$ billion at 2025 prices with shared scales across panels.
Use catalogue dimensions; other dimensions must stay fixed.
Complete working YAML
- chartpack:
format: gcubed-chartpack
version: 1.4.0
title: Sector output paths by region
sector_selection_dimensions:
- sectors
- layers
defaults:
start_year: 2025
end_year: 2035
- chart:
title: Sector output paths by region
chart_type: small-multiples
facet_dimension: regions
group_dimension: sectors
x_axis:
label: Year
y_axis:
label: Sector output (US$ billion, 2025 prices)
min: 0
caption: Small multiples share time and value scales so magnitude and shape remain comparable across facets.
series:
- variable_prefix: SYNTHSECTOR
selectors:
sectors: all
regions: all
QuestionHow does a reconciled total divide into components through time?
DataComplete nonnegative additive components and an authored total source.
UnitsUS$ billion at 2025 prices. Gross sector output is labelled sector output total, not GDP decomposition.
display_selector switches stacked area and bars without changing reconciliation. A filtered display may show only part of the complete source composition.
Complete working YAML
- chartpack:
format: gcubed-chartpack
version: 1.4.0
title: Illustrative North sector output total
sector_selection_dimensions:
- sectors
- layers
defaults:
start_year: 2025
end_year: 2035
- chart:
title: Illustrative North sector output total
chart_type: composition-area
show_labels: true
display_selector: true
x_axis:
label: Year
y_axis:
label: Sector output (US$ billion, 2025 prices)
min: 0
caption: Complete additive levels reconcile to the authored total; Display switches area and bars without changing data.
reconciliation:
total_variable: SYNTHTOTAL(USA)
absolute_tolerance: 0
series:
- variable_prefix: SYNTHSECTOR
selectors:
sectors: all
regions: USA
Preview the two populated contribution years, 2025 and 2030. level_base adds a derived absolute Level column to the report table without changing plotted contributions. Allocation still depends on layer order.
Complete working YAML
- chartpack:
format: gcubed-chartpack
version: 1.4.0
title: Ordered policy-layer contribution in 2030
sector_selection_dimensions:
- sectors
- layers
defaults:
start_year: 2025
end_year: 2035
- chart:
title: Ordered policy-layer contribution in 2030
chart_type: waterfall
show_labels: true
year: 2030
year_selector: true
level_base: 100
caption: Ordered contributions reconcile from zero; the report table derives an absolute level from base 100.
x_axis:
label: Policy layer
y_axis:
label: GDP change (US$ billion, 2025 prices)
min: -25
max: 5
series:
- variable: SYNTHGDPCHANGE(BASELINE,USA)
label: Baseline
role: start
- variable_prefix: SYNTHGDPCONTRIBUTION
selectors:
regions: USA
role: contribution
- variable: SYNTHGDPCHANGE(PACKAGE,USA)
label: Final package
role: total
Switch View from the time-axis heatmap to the region × sector matrix. Year then becomes a separate choice because it is no longer on either visible axis.
Heatmap
Activity by region and year
A semantic diverging palette anchors the authored midpoint; a time-axis heatmap has no Year control.
Year appears only in the matrix view, where neither visible axis is year. Import the grouped YAML and CSV to use the report controls.
Complete grouped-view YAML
- chartpack:
format: gcubed-chartpack
version: 1.4.0
title: Grouped heatmap views — synthetic guide
sector_selection_dimensions:
- sectors
- layers
defaults:
start_year: 2025
end_year: 2035
- chart:
title: Activity by region and year
chart_type: heatmap
show_labels: true
x_dimension: year
y_dimension: regions
x_axis:
label: Year
y_axis:
label: Region
color_axis:
min: 95
max: 115
midpoint: 100
palette: semantic-diverging
caption: A semantic diverging palette anchors the authored midpoint; a time-axis heatmap has no Year control.
series:
- variable_prefix: SYNTHINDEX
selectors:
regions: all
view_group: synthetic-guide-heatmaps
view_label: Regions × years
- chart:
title: Sector output by region in 2030
chart_type: heatmap
show_labels: true
x_dimension: regions
y_dimension: sectors
x_axis:
label: Region
y_axis:
label: Sector
year: 2030
year_selector: true
color_axis:
min: 0
palette: semantic-sequential
caption: Two model dimensions form a matrix; the report Year control retains the authored measure and bounds.
series:
- variable_prefix: SYNTHSECTOR
selectors:
sectors: all
regions: all
view_group: synthetic-guide-heatmaps
view_label: Sectors × regions
Preview Axes changes the authored heatmap dimension arrangement; axis selection is a YAML choice, not a report dropdown. Year, View, Observations and Display are report controls when enabled. Import the complete YAML and CSV to try live controls, current-view tables, filters and CSV/SVG/PNG actions.
Snapshot, matrix heatmap, paired scatter, one-year composition and waterfall examples preview eligible years. The waterfall source has contributions in 2025 and 2030; the report checks values and reconciliation before offering a year.
Group adjacent heatmap definitions. Each view carries its own measure, axes, units, caption, palette and bounds. The grouped example includes independently importable YAML.
Choose heatmap dimensions or paired X/Y variables in YAML. Labels override inferred titles on every chart type; numeric min/max bounds apply only to numeric axes. The time heatmap preview moves Year from X to Y, so Year stays visible on an axis in both states; the grouped View example shows Year as a separate choice.
For a zero-start waterfall, add an absolute Level column to the report table without changing source or plotted contributions.
Preview selectors swap pre-rendered SVGs. The report controls recompute the chart, caption, table and exports from the downloaded YAML and CSV.
Use these with real G-Cubed results
Imports used below
from pathlib import Path
import pandas as pd
from gcubed.experiments import generate_setup_artefacts
from gcubed.reporting import generate_all_simulation_results, generate_html_report
1 · Start from the catalogue
Choose exact variables and the right dataframe
Inspect charting_projections, including exact IDs, prefix, dimension descriptions, units, vector and region.
Choose levels, shares or deviations deliberately. Confirm price basis and additivity before composition or waterfall work.
Quote CSV IDs and metadata containing commas. Keep year columns as strings when constructing a pandas dataframe.
Use one compatible pack across every generated dataframe
generate_all_simulation_results applies the same chartpack to levels, baseline deviations and incremental deviations. It raises if any dataframe is incompatible; it does not silently skip composition.
Meaning:series-value on a deviation CSV compares the selected series’ deviations from the baseline in one chosen year. series-delta compares two years inside whichever dataframe was supplied.
4 · Report a chosen levels/share frame
Use the public single-report boundary for composition
Composition needs complete additive levels or shares. Pass that chosen dataframe directly instead of blindly using a composition omnibus pack for batch levels and percentage deviations.
Ordinary percentage deviations are not additive. Never stack them as shares or levels.
5 · Export ordered contributions
Opt in with exact source level IDs
Select exact additive level IDs from the real catalogue. The producer writes projections_data/layer-contributions.csv after ordinary reports. Baseline must be first in ordered all_projections.
Illustrative naming: source SYNTHGDP(USA) at ordered cumulative levels 1000 → 988 → 979 → 989 → 992 produces SYNTHGDPCHANGE(BASELINE,USA), SYNTHGDPCONTRIBUTION(LAYER_1,USA) … and SYNTHGDPCHANGE(PACKAGE,USA), with layer labels from the ordered projections. Values are 0, −12, −9, +10, +3 and −8.
6 · Render the waterfall separately
Pair contribution CSV with waterfall YAML
The contribution export does not automatically create waterfall HTML. Drop the waterfall YAML and contribution CSV together into a report, use the SVG CLI, or make a second public report call.
prefix, set_member_descriptions, description, units, vector, region
One column per year
Complete composition sources reconcile before filtering. The visible table may show only selected components; the source CSV and per-chart export retain all source components under current export policy. Waterfalls filter atomically, require role order start → contribution… → total, and allow only the configured reconciliation tolerance.
Uncertainty remains deferred. Fan or interval charts need exported ensembles or interval bounds. A collection of deterministic scenarios is not a confidence band.