Heaped TGraph

Hello rooters,
I’d like to fill a TGraph (with option B - bar chart - activated) with heaped data, using different colours. In the end I’d like to get for each value of the X axis a bar in which the length of each coloured part is proportional to the Y values in input. It is something similar to what one can do using a TStack with histograms. Is it possible to do that?
Thank you

Why not using thstack in that case ?