score:2
I wasn't going to post this question at first because I just found the answer (after searching in the docs for a while) but I figured this could help others.
Simply make sure you add the formatter callback
in your labels object:
yAxis: {
labels:{
formatter: function(){
if(this.value >= 0){
return this.value;
}
}
}
}
score:3
While your solution works, there is a slightly more generic solution you might like if your intent is always to prevent the yAxis having a label at the bottom left:
yAxis: {
labels: {
formatter: function() {
if ( this.isFirst ) { return ''; }
return this.value;
}
}
},
Making use of the isFirst
property that Highcharts has on this
prevents your reliance on "magic numbers" (similarly, there is an isLast
value if you'd like to try that -- though I don't see as much use for it).
Source: stackoverflow.com
Related Query
- Hide first yAxis label in Highcharts
- Highcharts axis label before first point
- Highcharts missing first date label on xAxis
- Show only first and last xAxis label in Highcharts
- Get x-axis label into the first colomn of the table - highcharts
- Why is the first label on highcharts bar chart missing?
- Hide or Disable Legend or Label in the end Highcharts line
- Highcharts label behind the second series (but above the first series)
- Highcharts display label for pie chart using html table as data source
- Highcharts addSeries yAxis Label Formatting
- highcharts - Hide some labels in yAxis
- My Highcharts graph with multiple axis ignores the max value I set for the first yaxis
- How to rotate first and last x-axis label in Highcharts chart?
- Hide first tick in Highcharts time series
- How to show only the last 100 candlesticks or hide the first 50 candlesticks in Highcharts Stock Chart?
- Add label for highcharts in first element
- Change first tick label on yAxis
- Highcharts with yaxis max property doesn't hide plotbands and lables
- How to show first and last label of x axis Highcharts
- Show only the first and last y-axis label on a graph highcharts
- Decimals on yAxis are not being displayed, even if that same code works on highcharts jsfiddle
- Highcharts - margin top to yAxis label
- Areaspline: edge to edge lines and hide first y label
- Hide the First Value Data in Series HighCharts
- Highcharts - How to format yAxis label to have single digit?
- Highcharts - How to hide the last category tick label on xAxis with scrollbar
- Adding same precision to the yAxis Label of HighCharts
- highcharts add yAxis label based on negative/positive value
- Highcharts - display label on yAxis
- HighCharts Hide Series Name from the Legend
More Query from same tag
- how do you call function to pull data automaticall to chart in highcharts
- Remove over all line in plot
- Highmaps min and max zoom level
- HighCharts add another series value into tooltip
- Angular HighCharts Heatmap will not display with error 15
- How to get the data labels below the xAxis in a column graph
- Highcharts/Highstock supported in Google Sites?
- Php and MySQL with Highchart
- mouseOver in Highcharts
- How to hide a specific x-axis label programmatically?
- Two tool tip for two different charts
- C# Parse string into arrays for HighCharts
- Show Highcharts tooltip at the bottom of the chart in responsive mobile version
- Highcharts solidgauge - repeatable div's - duplicate value in php variable
- Highcharts - how to position values closer to the Y axis
- Highcharts, add 'go back' (drill up) button when drill
- Highcharts SVG accessibility
- Adding multiple series to the spline chart using dotnet high charts in asp.net mvc3
- column chart color range for negative numbers and different color range for positive
- Highcharts resize doesn't always work
- Highcharts Highmaps How to change value for color axis in map bubble
- HighCharts Funnel with Centered Labels instead of on the right
- how to set the y-axis properly in solid gauge (highcharts)?
- MySQL DateTime - XAXIS HIGHCHART
- Reading MySQL data into highstocks
- How do I line up series points on a compare intervals graph?
- Highcharts - Getting a 3d effect with selected pie chart slices
- Highcharts create legend for waterwall and stack column chart
- HighChart Skipping the first point : Highcharts, Javascript
- JavaScript - Export Div with SVG chart + HTML as and Image