Search code examples
javascriptzoomcharts

Best chart to use to display percentage breakdown with ZoomCharts


I am trying to visualise "investment value" over "APR" and my data looks like this:

7.4: 2000
7.4: 300
7.9: 1000
8.0: 15000
8.0: 730
8.3: 700

Each line here represents a borrower, who offered to loan certain amount (on the right) at a certain APR (on the left). Sometimes multiple borrowers decide to loan different amounts at the same rate.

From the gallery it appears that this is the most suitable example: https://zoomcharts.com/en/gallery/all:time-chart-stacked-bars-global-emissions, however I am using percentages and not time. Also even though it might make sense to stack 2000 and 300 on top of 7.4%, they are not different series.

What would be the most suitable zoomchart setting for this?


Solution

  • I would suggest using FacetChart - in that you can have any value on X axis, while still having a value on the Y axis. Here is an example:

    https://zoomcharts.com/en/gallery/facet-chart:facet-chart-browser-shares

    or if you have multiple values per one "x" value, you can use stacking of series like here:

    https://zoomcharts.com/en/gallery/facet-chart:facet-chart-legend