gpt4 book ai didi

android - 使用MPAndroid图表绘制立方折线图

转载 作者:太空宇宙 更新时间:2023-11-03 11:34:35 26 4
gpt4 key购买 nike

我正在尝试绘制这样的立方线图:

enter image description here

使用 MPAndroid 图表库。

我可以画线,但不能画 X 轴和线之间的填充,如图所示。
浏览了图书馆和许多 SO 问题。

最佳答案

我想你需要这个:

LineDataSet dataset = new LineDataSet(vals, null);

dataset.setDrawFilled(true);

setDrawFilled(boolean filled)

Set to true if the DataSet should be drawn filled (surface), and not just as a line, disabling this will give great performance boost! default: false

您还可以控制透明度:

setFillAlpha(int alpha)

sets the alpha value (transparency) that is used for filling the line surface (0-255), default: 85

和颜色:

setFillColor(int color)

sets the color that is used for filling the line surface

关于android - 使用MPAndroid图表绘制立方折线图,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/34181849/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com