score:47
Accepted answer
You can change the labels by using a label formatter. Assuming your data is formed appropriately, you can do something like the following:
var yourLabels = ["Very Low", "Low", "Medium", "High", "Very High"];
var yourChart = new Highcharts.Chart({
//...
yAxis: {
labels: {
formatter: function() {
return yourLabels[this.value];
}
}
}
//...
});
score:14
Declare an object which will be used to switch the values you want to change, like the following.
var change = {
0: 'Very Low',
5: 'Low',
10: 'Medium',
15: 'High',
20: 'Very High'
};
Then on your chart options use labels formatter to switch it.
yAxis: {
labels: {
formatter: function() {
var value = change[this.value];
return value !== 'undefined' ? value : this.value;
}
}
}
Source: stackoverflow.com
Related Query
- HighCharts Bubble Chart: text for axis interval labels
- Highcharts text labels for y-axis
- How to position labels for plotbands on y axis in Highcharts
- How To Show All Data Labels For Datetime Axis In Highcharts
- Multiple images for Highcharts X Axis Labels
- How to add text labels to a numerical x axis in Highcharts
- Dynamic Labels for X axis in HighCharts
- Width for labels on x Axis with grouped Categories in Highcharts
- How to hardcode arbitrary Tick text labels on y axis in highcharts
- Highcharts - set maximum range for yAxis but keep axis dynamic within that range
- Highcharts not displaying data labels for Pie chart in arabic
- Highcharts X-Axis labels as Text
- Highcharts - Long multi-line y axis labels causing following label to be removed
- Highcharts - with datetime axis labels overlap
- Tooltip text alignment in Highcharts for 'direction: rtl'
- Why are the labels for my opposite yaxis in Highcharts not showing up?
- Labels are not rendering for plotLines highcharts
- In highcharts, is it possible get the exact position of x axis labels for overlap detection purpose?
- Highcharts Line - When Y axis min is set to 0, connecting line isn't shown for consecutive 0 values
- Using PhantomJS to create HighCharts grahps server side for use in PDF creation (PHP) - results in exit code 11 from PHPs exec();
- Highcharts - Multiple Axis Graph not displaying labels
- Show some specefic number on gauge highcharts axis labels
- Displaying additional text for Highcharts Bubble chart
- highcharts - precision for stacked column chart data labels
- How to adjust line-height/ellipses in Highcharts axis labels
- Highcharts x axis label text wrapping lost on setting label step
- Highcharts -- Can't apply style to x axis labels
- How do I put Icons in the y Axis for a Dynamic Highcharts chart?
- Highcharts Gauge Chart with text labels
- Highcharts change label text for a single series
More Query from same tag
- Highcharts series rendering problems
- How do I get the value of a highcharts graph point on mouseover?
- How to format dates in Highcharts on x-axis?
- Highcharts - xAxis date
- Make HTML element fill rest of page
- putting a semi-transparent div over a highcharts graph
- Building sparse array
- How to give time labels consistently in polar highcharts?
- How to ser Highchart Grid Color pattern
- Highcharts Legend 'enabled' function not working
- Highcharts solid gauge dynamic update
- Show Data For Grouped Series in ToolTip Highcharts
- clearing interval inside highcharts (React)
- Ionic3 Highcharts-More import Error --JsAllow Not Set
- Same data in HighCharts and HighStock
- Highcharts - curves goes outside the box
- Fixed y-axis label width in Highcharts
- Django query database and send data to template
- Random number on Highcharts + AngularJS
- Highcharts basic line chart - Y-axis label name
- Javascript Highcharts Mapping multiple values without showing them all in the chart
- Export json data with highcharts
- Is it possible to combine two column charts in a single Highcharts chart?
- HighCharts Data and Legend Ordering
- Scrollbar creating overlaping chart div
- Highcharts: Additional legend items to control multiple items
- How to Disable Highchart Unit Display None
- Xaxis data given to highcharts in descending order but still xaxis appears in ascending order
- HighCharts: Drilldown to a Stacked Column
- Hightchart map pie : clic and hide specific pie