An Example of a Google Bar Chart
HTML
<script type="text/javascript" src="https://www.gstatic.com/charts/loader.js"></script>
<div id="chart_div"></div>
JavaScript
google.charts.load('current', {packages: ['corechart', 'bar']});
google.charts.setOnLoadCallback(drawBarColors);
function drawBarColors() {
var data = google.visualization.arrayToDataTable([['Month', 'Who is hiring', 'Who wants to be hired'], ['July-2021', 1001, 197], ['August-2021', 912, 264], ['September-2021', 973, 229], ['October-2021', 868, 238], ['November-2021', 1031, 286], ['December-2021', 844, 232], ['January-2022', 776, 264], ['February-2022', 899, 291], ['March-2022', 888, 293], ['April-2022', 808, 209], ['May-2022', 856, 308], ['June-2022', 811, 257]]);
var options = {
title: 'Who is hiring vs. Who wants to be hired',
/*chartArea: {width: '60%'},*/
colors: ['#ff0000', '#0000ff'],
height: 400,
width: 700,
hAxis: {
title: 'Number of posts',
minValue: 0,
maxValue: 1100,
viewWindow: {
max: 1100,
},
},
vAxis: {
title: 'Month'
}
};
var chart = new google.visualization.BarChart(document.getElementById('chart_div'));
chart.draw(data, options);
}