Hello,
I would like to create a merit order graph in stata (as I will have to automatize the graph generation). On the y-axis the costs per unit generated are displayed. On the x-axis the accumulated capacity is displayed. The bar width is defined by the generation capacity of one country. The color of the bar is defined by the country iso digit.
The data looks like this:
It should look like the figure attached:
(source: Kranner)
I have tried to use the graph command but was not able to achieve the result above.
Thank you very much in advance
Martin
I would like to create a merit order graph in stata (as I will have to automatize the graph generation). On the y-axis the costs per unit generated are displayed. On the x-axis the accumulated capacity is displayed. The bar width is defined by the generation capacity of one country. The color of the bar is defined by the country iso digit.
The data looks like this:
INDEX | country (defines color) | cost (x-axis) | capacity (bar width) |
1 | EH | 18.495 | 50.00 |
2 | EH | 18.495 | 100.00 |
3 | EH | 18.495 | 170.00 |
4 | EH | 18.671 | 60.00 |
5 | MA | 19.639 | 20.00 |
6 | MA | 19.764 | 400.00 |
It should look like the figure attached:

I have tried to use the graph command but was not able to achieve the result above.
Thank you very much in advance
Martin
Comment