I want to use wxPlotCtrl or wxMathPlot to plot some scientific graphs, for example bode plots.
To do this properly it is necessary to have logarithmic scaled axis, but as far as i can see there is no way to realise this!?
Does anyone have an idea how to implement this in wxPlotCtrl or wxMathPlot?
Talk here about issues with one of the components hosted at wxCode, or suggest features for it.
2 posts • Page 1 of 1
You can always plot (x, log10 (y)), but then the units of y will be log10 (y). You can get the correct labels using double a = log10 (Ymax / Ymin) / N; where you want N intervals between the ticks. The values to write will then be Ymin * pow (10.0, a*n) for the nth tick. n=0 gives Ymin and n=N gives Ymax. To use this, however, you will need to hide the y-axis and to draw the tick text yourself.
Who is online
Users browsing this forum: Baidu [Spider] and 1 guest