Make Highcharts pick a smart y-axis min - charts

For a bar or column chart in Highcharts, is there a setting(s) to make it automatically set the min of the y-axis based on the min of the data? For example, if my data values fall between 200 and 300, then the plot doesn't look so good if the chart y-axis starts at 0, but rather it looks much better if the y-axis min is 200.
My current approach is supply the yAxis.min setting the minimum vale from the data subtracted by some "smart offset" (smart offset so that the min of the data is not plotted at the very bottom). The problem is i'm not 100% yet how to calculate that "smart offset" so I'm wondering if Higcharts can do the min from the data for me (rather than supplying it), then it might be able also figure out that offset.

You need to enable softThreshold property:
softThreshold: boolean
When this is true, the series will not cause the Y axis to cross the
zero plane (or threshold option) unless the data actually crosses the
plane. (...)
series: [{
softThreshold: true,
...
}]
Live demo: http://jsfiddle.net/BlackLabel/05tgmz9c/
API Reference: https://api.highcharts.com/highstock/series.column.softThreshold

Related

FusionCharts column_2D chart

How to set the y-axis interval, or 'tick mark?' with a min value of 0 and max value of 9, I'm seeing tick marks every '2', like 0,2,4,6,8,10. I don't want that.. I want y-axis lines every .25
Funny, in fusion charts I can set the background color of the yaxis labels, put a dashed border around the background, even control the space size between the dashes.. but I can't set something important like the tick mark interval
FusionCharts supports 'numDivLines' that allows you to specify the number of divisions on the y-axis. The number of lines required for the chart can be calculated using min and max values. Set 'adjustDiv' to 0. This will force fusioncharts to use the user-defined 'numDivLines'.
JS-Fiddle: https://jsfiddle.net/spranali/yvmq0ab1/44/
adjustDiv: 0,
numDivLines: 35,
yAxisMinValue: 0,
yAxisMaxValue: 9,
The height of the chart has to be scaled to occupy the specified y-axis intervals.

Highstock charts - Show the blank space up to the current date

Currently, I'm having trouble to force the highstock chart to display a blank space up to the current date. It focuses the data I give it.
What I have is:
What I want is something like this
As you can see I want the data to stop at the date of the latest data point and then the graph should show a blank space and stop at the current date. Obv there is not data points for those times
You can control how empty points, and missing points are shown by looking at:
xAxis.ordinal
In an ordinal axis, the points are equally spaced in the chart regardless of the actual time or x distance between them. This means that missing data periods (e.g. nights or weekends for a stock chart) will not take up space in the chart. Having ordinal: false will show any gaps created by the gapSize setting proportionate to their duration.
xAxis.max
The maximum value of the axis. If null, the max value is automatically calculated.
plotOptions.series.connectNulls
Whether to connect a graph line across null points, or render a gap between the two points on either side of the null.
Which means that for your graph, you will want to set:
xAxis: {
ordinal: false,
max: (new Date()).getTime() //to set the current date and time as a maximum
}

Tableau - Fixed count of datapoints per pane

I'm trying to build a shewhart-style control chart in Tableau and having trouble with setting a fixed sample size for the data points plotted on the chart. Consistent sample sizes are critical for setting accurate control limits so I'm dead in the water until I can specify that tableau only use 10-30 random rows to calculate each point on the chart.
I thought I could accomplish this by returning a random number in my query and filtering on the top N results for each pane but I can't seem to wrap my head around how to actually execute that.

ECharts generated label overlaps with dataZoom

Using ECharts I am giving it a data series that consists of a number of data against really values. (e.g plotting stock prices).
I also have data zoom enabled.
My issue is that the generated X axis' labels overlap with the dataZoom. I can't understand from the documentation how to fix this.
You need to set the value of grid.bottom. This will move the whole grid further from the bottom of the canvas and pull the whole X Axis with it.
Example: grid: { bottom: 60 }
// usage
this._displayedChart.setOption({ grid: { bottom: 10 } })
Not a great solution but works.
https://ecomfe.github.io/echarts-doc/public/en/option.html#grid.bottom

Cognos Chart with "No Data Available" although list shows data

I am completely new to Cognos, so sorry if I don't state some necessary information. I can't go into specifics about my chart, but here is the background:
I have a SQL code running into my Query
My chart and list use the same Query and have the exact same fields
My chart is a basic line graph
When I change my aggregate function to total for my y-axis, then I can see the data points
I do not want to use an aggregate function (I need to see all the points for my x and y-axis)
My x-axis is only one object, but it has multiple y-axis values within a year (which is my series). Ex:product-cost-year list,
where my product is the x-axis, cost is the y-axis, and series is year.
How can I get my chart to appear with all my data points? Eventually, I would like to add an upper and lower confidence interval to this chart.
One way to solve this issue is to create another column that simply counts the number of products (1,2,3,...9). We will call this column count. Keep all your fields the same (product for x-axis, cost for y-axis, and year for series). You will want to add count underneath product on the x-axis. You should see your mouse pointer turn to a horizontal line and it will place it under and to the right of product. Make sure not to place it just to the right of product.