score:16
We do have tooltip formatter options to display the value as number instead of percentage
http://api.highcharts.com/highstock#tooltip.formatter
tooltip: {
formatter: function() {
return '<b>'+ this.point.name +'</b>: '+ this.point.y ;
}
},
this.point.y will do the trick (now you have this.percentage in that place)
score:0
tooltip: {
pointFormat: "Percentage: {point.percentage:.2f}"
}
This will give you the percentage value
score:6
tooltip: {
pointFormat: "Value: {point.y:.2f}"
}
this is not for formating the values .
var data = [{
name: 'Population',
data: [],
dataLabels: {
enabled: true,
rotation: -90,
color: '#FFFFFF',
align: 'right',
x: 4,
y: 10,
style: {
fontSize: '13px',
fontFamily: 'Verdana, sans-serif',
textShadow: '0 0 3px black'
}, formatter: function() {
return Highcharts.numberFormat(this.y, 2, '.');
}
}
}];
the formart of the values can be change in the dataLables in the data .
score:14
You can just format it like this below.
tooltip: {
pointFormat: "Value: {point.y:.2f}"
}
score:19
plotOptions.pie.dataLabels.formatter
is a function that will let you format the label. In this case I returned this.percentage.toFixed(2)
which will trim your number at 2 decimal places. Demo at this jsFiddle
plotOptions: {
pie: {
dataLabels: {
formatter: function() {
return '<b>' + this.point.name + '</b>: ' + this.percentage.toFixed(2) + ' %';
}
}
}
},
Source: stackoverflow.com
Related Query
- Number Formatting at Highcharts Chart Values?
- Total of values in HighCharts Pie Chart
- Highcharts - best way to handle and display zero (or negative) values in a line chart series with logarithmic Y axis
- Highcharts Column chart with drilldown, remove hyperlink like formatting from x-axis labels
- Hide 0 values in Stacked Column Chart in Highcharts
- AJAX displaying values from two different functions in a single Highcharts chart instead of two different ones
- Highcharts - Area Chart - Stacking with series containing negative and positive values
- Highcharts Gauge chart is rounding down max number
- HighCharts Stock Chart error code 18
- Highcharts multiple column chart with drilldown, correct formatting of drilldown axes
- passing json values to highcharts from .net code behind
- passing formatting JavaScript code to HighCharts with JSON
- Column Chart Show datalabel for null values - Highcharts
- Set the number formatting in general for a Highcharts chart?
- Highcharts - draw line chart with summed values but show breakup on hover
- How to remove decimal values on x-axis of bar chart : Highcharts
- Highcharts - Dealing with small values in Funnel chart
- Hide the zero values in a Scatter/Column chart in highcharts
- Column chart with negative values and categories on xAxis in HighCharts
- Highcharts Column Chart Not Displaying Dynamic Values
- Highcharts - show series values outside chart container?
- Highcharts - Pie chart with negative values
- Highcharts display label for pie chart using html table as data source
- highcharts lollipop/dumbbell chart change position/colour of positive and negative marker values
- remove gap below highcharts area chart when all values are zero
- Highcharts Pie Chart data formatting
- Highcharts JS 'columnrange' chart value formatting
- Highcharts pie chart plotting different values
- Highcharts how to make a set number of colors for pie chart data and drilldown data
- Highcharts sticky labels for big values goes out of chart
More Query from same tag
- single array timestamp as xAxis for multiple series
- HighChart Boost Module in highmaps not working
- Highstock - Comparison chart should be start with 0%
- how I can get a static tooltip on a plotline, highstock?
- Best way to add different colours based on conditions to bargraphs plotted with Highcharts.js
- highcharts: margin between two boxplot series
- Style highcharts x and y axis
- Get x value of highstock navigator handle when mouseup occurs
- Dynamically created highchart not showing bars/lines
- Choose which data to display on Highcharts
- In Highstock, overlapping flags when existing multiple series
- Highcharts - specifying order of stacked time series
- Adding Maplines in HighMaps using geojson file
- How to show values in Highcharts tooltip other than x and y when data points are too high?
- Error scraping Highcharts in Python with selenium
- highcharts-react-native not working in iOS binary (.ipa)
- Highcharts - Series tooltip doesn't work when plotting lines that zigzag on the x axis
- HighCharts Heatmap with motion
- Is there any way to merge this two x-axis in one axis?
- Create log scale in highstock
- Highcharts Error #16: charts not showing on the same page
- Highchart axis 2 decimal places
- drawing start and end time as intervall in one thick line
- Highcharts: X and Y Axis cross at zero in scatter chart
- Chart rendering issue when hiding all series via clicking on legends
- High Chart X Axis to display month and year
- python/flask/Jinja2 and Json
- Line chart series drilldown to another linechart series
- Highstock xAxis label formatting
- Is there any way to fill bubbles partially in highcharts bubble chart?