I think you can achieve that with stackedBarChart
.
Here in the docs you can see how to add the data for each bar.
With this, you will set the data for a barchart as follows:
BarEntry(xPosition, floatArray(belowLineNumber, aboverLineNumber)
For the colors, you just need to add a list of colors fot the data set(two colors in your specific case):
dataSet.color = listOf(YourColor1, YourColor2)
Hope it helps!
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…