Thanks for reporting the use-case. For now, you can workaround this issue by setting minimum of axisY as shown in this JSFiddle.
Considering this thread as duplicate of Issues With Same Value < 1 On Logarithmic Axes and hence closing the same.
—-
Manoj Mohan
Team CanvasJS
You can use x-value instead of label & use scaleBreak to remove gap of non-trading hours. Please take a look at this JSFiddle for an example on removing weekend gap.
—-
Manoj Mohan
Team CanvasJS
You can set viewportMaximum for x-axis with some margin upon updating dataPoints as shown in this JSFiddle.
—-
Manoj Mohan
Team CanvasJS
rodolfo,
To sort the dataPoints for multi-series bar chart, you need to sort the dataPoints for each of data series present in the multi-series bar chart. Please take a look the code snippet below for the same.
chart.options.data.forEach(function(element) {
element.dataPoints.sort(compareDataPoint);
});
function compareDataPoint(dataPoint1, dataPoint2) {
// instead of label you can also use dataPoint.x or dataPoint.y depends on you requirment
if (dataPoint1.label < dataPoint2.label){return -1}
if ( dataPoint1.label > dataPoint2.label){return 1}
return 0
}
Also, check out this JSFiddle for the complete working code.
If you are still facing the issue, can you kindly create JSFiddle reproducing the issue you are facing and share it with us along with further briefing so that we can understand your scenario better and help you out?
—-
Manoj Mohan
Team CanvasJS
[UPDATE]
We have just released StockChart v1.10.7 with this bug fix. Please refer to the release blog for more information. Do download the latest version from download page & let us know your feedback.
Thanks for reporting the use-case. The issue seems to be happening when navigator is disabled. We will fix this issue in our future versions. However, you can achieve your requirement using Chart instead of StockChart (using canvasjs.stock.min.js, you can create both Chart and StockChart) as shown in this JSFiddle.
—-
Manoj Mohan
Team CanvasJS
Can you kindly create JSFiddle and share it with us (or a sample project and share it with us over Google-Drive or OneDrive) along with further briefing about the issue you are facing so that we can look into code / chart-options being used, understand the scenario better and help you out?
—-
Manoj Mohan
Team CanvasJS
We are busy implementing some other important features at this point of time. Hence, there is no definite timeline.
—-
Manoj Mohan
Team CanvasJS
Please take a look at this JSFiddle for creating histogram chart using Column chart and setting dataPointWidth based on axis width and number of dataPoints.
If this doesn’t fulfill your requirements, kindly share pictorial representation and brief us further about your requirement so that we can understand your scenario better and help you out.
—-
Manoj Mohan
Team CanvasJS
We constructed the txt file with sample / dummy data in the format that you have shared – which was approx 150MB. We observed that the time taken to read txt-file and parse the data to the format accepted by CanvasJS is approx 7 seconds. And it’s taking few more seconds to render 7 million datapoints. We observe that in the JSFiddle that you have shared you are trying to read txt file and render chart every second which might be causing issue. We recommend you to read txt file every 30 seconds or 1 minute to improve the performance of your application. Also, you can filter / group the data to reduce number of dataPoints to be shown within a part of screen than trying to visualizing 7 millions of dataPoints. Filtering / data-grouping will also improve the performance, which you can achieve with the help of rangeChanging event as shown in this JSFiddle.
—-
Manoj Mohan
Team CanvasJS
We are sorry for the inconvenience caused but as of now, we don’t have any method to release the memory as garbage collection is performed by the browser. Please refer to this article for more information on garbage collection.
—-
Manoj Mohan
Team CanvasJS
You can set viewportMinimum and viewportMaximum to null to hide axisLabels on hiding the dataSeries as shown in this updated JSFiddle.
—-
Manoj Mohan
Team CanvasJS