Figure - final result of basic bar (which show diff. colors according to its data)
Created
March 19, 2018 14:43
-
-
Save amelieykw/e93ff6aebfd76c6db0c9cad05a3731b5 to your computer and use it in GitHub Desktop.
[HighChart - Basic Bar Chart] #BasicBar #Highchart
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script src="https://code.highcharts.com/highcharts.js"></script> | |
<script src="https://code.highcharts.com/modules/exporting.js"></script> | |
<div id="container" style="min-width: 310px; max-width: 800px; height: 400px; margin: 0 auto"></div> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Highcharts.chart('container', { | |
chart: { | |
type: 'bar', | |
backgroundColor: 'transparent' | |
}, | |
title: { | |
text: '' | |
}, | |
xAxis: { | |
categories: ['APP Early Testing', 'APP QA PTRs Aging', 'QA NRE Coverage', 'QA Maturity', 'APP Delivery Quality', 'APP PRD Health', 'QA Deflection rate', 'QA Effectiveness'], | |
title: { | |
text: null | |
} | |
}, | |
yAxis: { | |
min: 0, | |
max: 100, | |
title: { | |
text: '' | |
}, | |
labels: { | |
overflow: 'justify' | |
} | |
}, | |
tooltip: { | |
valueSuffix: ' ' | |
}, | |
plotOptions: { | |
bar: { | |
dataLabels: { | |
enabled: true, | |
style: { | |
fontSize: '15px', | |
fontWeight: 'bold', | |
color: 'black' | |
} | |
}, | |
zones: [{ | |
value: 20, // Values up to 10 (not including) ... | |
color: 'red' // ... have the color blue. | |
},{ | |
value: 80, | |
color: '#7cb5ec' // Values from 10 (including) and up have the color red | |
},{ | |
color: 'green' // Values from 10 (including) and up have the color red | |
}] | |
} | |
}, | |
credits: { | |
enabled: false | |
}, | |
series: [{ | |
name: ' ', | |
data: [55, 95, 63, 47, 65, 71, 36, 98], | |
}] | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment