I want to create a boxplot chart with zones using Highcharts. It seems that highchart uses the high value as threshold.
Does anyone know if it is possible to change that to use the median for example ?
See https://stackblitz.com/edit/highcharts-boxplot-zones
Thanks !
Well, the chart renders exactly as you instruct it.
760, 801, 848, 895, 1265
If you want a different chart you would change the variables. In each case, the chart is rendering boxplots according to your data.
It is not officially supported, but you can set zoneAxis for example to 'median':
series: [{
data: [ // low, q1, median, q3, high
...
],
...,
zoneAxis: 'median'
}]
Live demo: http://jsfiddle.net/BlackLabel/6m4e8x0y/5001/
API Reference: https://api.highcharts.com/highcharts/series.boxplot.zoneAxis
Related
I´m setting up a preview for a graph, and I want to know if highcharts has any option for reducing the number of points showed in a series. I have points everyday in 5 years, and I would like to reduce for a simple preview. Is this possible?
You can reduce the number of points by your own function, but I think that the best solution will be to use provided by Highstock dataGrouping feature:
series: [{
dataGrouping: {
enabled: true
},
data: [...]
}]
Live demo: http://jsfiddle.net/BlackLabel/3ky0s2oh/
API Reference: https://api.highcharts.com/highstock/plotOptions.series.dataGrouping.enabled
Docs: https://www.highcharts.com/docs/stock/data-grouping
I'm trying to implement a heatmap in highcharts with a logarithmic colorAxis, however, I keep getting highcharts error #10 (can't plot zero or subzero values on a logarithmic axis).
As I'm trying to apply the logarithmic property to the color axis and not the actual axis themselves, I believe my problem is caused by some of my bins having a frequency of zero (A heatmap colors by the frequency in each bin).
How can I get around this? Can I create a default function so that when a frequency is zero it assigns that bin a default color? I can't find any solutions in the docs.
Currently, my colorAxis object looks like this
colorAxis: {
type: 'logarithmic',
minColor: '#EEEEFF',
maxColor: '#000022',
stops: [
[0, '#EFEFFF'],
[0.67, '#4444FF'],
[1, '#000022']
]
}
My solution was to iterate through my data and change all the zeros to an extremely small number then set a min property on the colorAxis so the extremely small numbers would not interfere with the color scheme. This is obviously not the best solution because if the third dimension was measuring something other than frequency and this other thing could be a fraction less than 1 then the extremely small value could overlay with actual data and throw off the color scheme. Hopefully someone comes along and provides a better solution, but for now this is all the insight I have to give.
Logarithm doesn't have any value in 0 so your solution seems pretty neat. You need to apply some offset to the values that equal 0 - there's no other way.
If you want to be more consistent you can apply the offset to all the values. Then apply formatters(tooltip, data labels, color axis' labels) so that the user sees the value without the offset.
Live demo: http://jsfiddle.net/kkulig/jdf5wrdL/
I have a jqplot chart with 8 series. 7 of these are normalized in such a way that they look great with the default yaxis. The last series, however, needs to utilize a secondary yaxis. There are a ton of examples on utilizing a dual yaxis presentation when there are only two series.
So my question: Can you assign a specific series to a specific axis? If so, how?
Thanks in advance!
Ok -- I ended up finding an example in the api docs, where previously I was searching through the examples.
{
series:[
{color: '#ff4466', lineWidth: 5, label:'good line'},
{yaxis: 'y2axis', shadow: false, label:'bad line'}
]
}
The yaxis option is available per series, which allows a specific series to be assigned to a specific yaxis.
I hope this helps someone else.
I am working with Column Chart (amCharts). When I put data like 10352, 40, 103, 1 etc. I only see 10352 column. I know there is an option in google charts called logScale, which handles the small and big data. Is there any similar option in amCharts?
To turn on logarithmic scale for a value axis in amCharts use its logarithmic property. I.e.:
"valueAxes": [{
"logarithmic": true
}]
Here's an example at amcharts.com that uses logarithmic scale to display dramatically different values in scale:
http://www.amcharts.com/demos/logarithmic-scale/
I need to create one graph with its x-axis should be
0,1,2..10
y-axis should be out current time + next 10 times with an interval of five minites.
like this
array = [1.45, 1.50, 1.55, 2.00, 2.05, 2.10, 2.15, 2.20, 2.25, 2.30];
Any body can help me with some sample codes.
Thanks
Look at the charts libraries like flot. Or if you have to write your own code I'd suggest looking at Canvas.
If you want an easy javascript graphing solution check out Highcharts
You should also have a look at Google Charts. Look at the line graph examples.