Charting with Multiple Scenarios
To create a chart that displays data from more than one scenario, just use a scenario attribute on a vdl-chart-series element.
Set its value to the index of the scenario you wish to use as the source of the data.
<vdl-chart>
<vdl-chart-series type="bar" entity="FactorySupply" scenario="0">
<vdl-index-filter set="Factories" value="New York">
</vdl-index-filter>
</vdl-chart-series>
<vdl-chart-series type="bar" entity="FactoryDemand" scenario="1">
<vdl-index-filter set="Factories" value="Paris">
</vdl-index-filter>
</vdl-chart-series>
<vdl-chart>
Pie charts are an exception to this principle, as multiple pie charts cannot be overlaid. In this case, you can draw multiple pie charts separately using the
vdl-repeat attribute of
vdl-chart, indexing through the scenarios as required.
<vdl-chart vdl-repeat="=s,i in scenarios"
title="Multi-scenario, Multi-entity">
<vdl-chart-series type="pie" entity="ServiceLevelAgreements" scenario="=i">
</vdl-chart-series>
</vdl-chart>
