简体   繁体   English

带有wxMathPlot的离散图/条形图

[英]Discrete graph / bar graph with wxMathPlot

I have a wxWidgets programm with gcc compiler and wxSmith which shows how many licenses are used at what time. 我有一个带有gcc编译器和wxSmith的wxWidgets程序,它显示了什么时间使用了多少个许可证。 Therefore I managed to integrade a wxMathPlot graph but unfortunately it connects all points as you can see below. 因此,我设法整合了wxMathPlot图,但不幸的是,它连接了所有点,如下所示。 在此处输入图片说明

As you can imagine, that is not ideal for such a graph as I have discrete update times and between them the licenses are the same. 可以想象,对于这样的图形,这不是理想的选择,因为我具有离散的更新时间,并且它们之间的许可是相同的。 So I would not have growing lines but something like a bar graph. 因此,我不会增加线条,而是像条形图那样。 Is there a way to make a discrete graph using wxMathPlot? 有没有办法使用wxMathPlot制作离散图? I would not like to use another graph plugin. 我不想使用其他图形插件。

Thank you for your help and sorry if the mathematical terms are not correct. 感谢您的帮助,对于数学术语不正确的情况,我们深表歉意。

I found a workaround for this problem. 我找到了解决此问题的方法。 It is still a graph like the one above, but when you add entries only a small fracture before the number of licenses changes, with the same number of licenses as the entry before, the gradients are either 0 or near infinity. 它仍然像上面的图一样,但是当您添加条目时,在许可证数量更改之前只有很小的裂口,并且许可证数量与之前的条目相同,渐变为0或接近无穷大。 在此处输入图片说明

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM