<!doctype html>
<html class="zc-html">
<head>
<meta charset="utf-8">
<title>ZingSoft Demo</title>
<script nonce="undefined" src="https://cdn.zingchart.com/zingchart.min.js"></script>
<style>
.chart--container {
height: 100%;
width: 100%;
min-height: 530px;
}
.zc-ref {
display: none;
}
</style>
</head>
<body class="zc-body">
<div id="myChart" class="chart--container">
<a href="https://www.zingchart.com/" rel="noopener" class="zc-ref">Powered by ZingChart</a>
</div>
<script>
ZC.LICENSE = ["569d52cefae586f634c54f86dc99e6a9", "b55b025e438fa8a98e32482b5f768ff5"]; // CHART CONFIG
// -----------------------------
let chartConfig = {
type: 'mixed',
theme: 'classic',
backgroundColor: '#e5e5e5 #ccc',
title: {
text: 'Sales Comparison 2018 vs 2019',
backgroundColor: '#555',
},
plot: {
barsOverlap: '55%',
},
plotarea: {
margin: '80px 60px 35px 60px',
},
scaleX: {
values: [
'Jan',
'Feb',
'Mar',
'Apr',
'May',
'Jun',
'Jul',
'Aug',
'Sept',
'Oct',
'Nov',
'Dec',
'Jan',
'Feb',
'Mar',
'Apr',
'May',
'Jun',
],
guide: {
visible: false,
},
item: {
fontColor: '#333',
},
lineColor: '#db0a0a',
lineWidth: '3px',
tick: {
lineColor: '#db0a0a',
lineWidth: '3px',
placement: 'outer',
size: '8px',
},
},
scaleX2: {
values: [
'MR 1',
'MR 2',
'MR 3',
'MR 4',
'MR 5',
'MR 6',
'MR 7',
'MR 8',
'MR 9',
'MR 10',
'MR 11',
'MR 12',
],
guide: {
lineColor: '#333',
visible: true,
},
item: {
fontColor: '#555',
},
itemsOverlap: true,
label: {
text: 'Marketing Report',
fontColor: '#333',
},
lineColor: '#07be07',
lineWidth: '3px',
tick: {
lineColor: '#07be07',
lineWidth: '3px',
placement: 'outer',
size: '8px',
},
},
scaleY: {
values: '0:100:20',
guide: {
visible: false,
},
item: {
padding: '5px',
fontColor: '#333',
},
label: {
text: 'Number of New Clients Acquired',
fontColor: '#333',
offsetX: '8px',
},
lineColor: '#db0a0a',
lineWidth: '3px',
tick: {
lineColor: '#db0a0a',
lineWidth: '3px',
placement: 'outer',
size: '8px',
},
},
scaleY2: {
values: '0:8000:2000',
guide: {
lineColor: '333',
lineStyle: 'solid',
visible: true,
},
item: {
padding: '5px',
fontColor: '#333',
},
label: {
text: 'Marketing Dollars Spent',
fontColor: '#333',
},
lineColor: '#07be07',
lineWidth: '3px',
multiplier: true,
tick: {
lineColor: '#07be07',
lineWidth: '3px',
placement: 'outer',
size: '8px',
},
},
series: [{
type: 'bar',
text: '2017 Sales',
values: [
36, 30, 20, 41, 26, 21, 23, 34, 21, 21, 15, 35, 29, 31, 15, 17, 21, 26,
],
tooltip: {
text: 'Number of New Clients<br>Acquired In %k 2018<br>%v',
},
backgroundColor: '#595959 #777',
hoverState: {
visible: false,
},
zIndex: 1,
},
{
type: 'bar',
text: '2018 Sales',
values: [
42, 24, 28, 36, 34, 28, 21, 19, 18, 22, 26, 24, 29, 30, 29, 19, 17, 20,
],
tooltip: {
text: 'Number of New Clients<br>Acquired In %k 2019<br>%v',
},
backgroundColor: '#db0a0a #ed0909',
hoverState: {
visible: false,
},
zIndex: 2,
},
{
type: 'line',
text: '2018 Marketing',
values: [
4470, 6300, 4590, 4500, 5550, 6500, 4775, 4950, 4400, 4100, 4800, 5100,
],
tooltip: {
text: 'Marketing Dollars Spent<br>Per Report %k 2019<br>$%v',
},
aspect: 'spline',
lineColor: '#07be07',
marker: {
backgroundColor: '#07be07',
borderColor: 'fff',
borderWidth: '1px',
size: '4px',
},
scales: 'scale-x-2, scale-y-2',
zIndex: 4,
},
{
type: 'line',
values: [
3650, 4000, 5150, 5150, 3800, 6100, 6800, 4000, 4030, 3100, 2090, 4100,
],
tooltip: {
text: 'Marketing Dollars Spent<br>Per Report %k 2018<br>$%v',
},
alpha: 0.5,
aspect: 'spline',
lineColor: '#595959',
marker: {
alpha: 0.5,
backgroundColor: '#595959',
borderWidth: '0px',
size: '4px',
},
scales: 'scale-x-2, scale-y-2',
},
],
};
// RENDER CHARTS
// -----------------------------
zingchart.render({
id: 'myChart',
data: chartConfig,
});
</script>
</body>
</html>
// CHART CONFIG
// -----------------------------
let chartConfig = {
type: 'mixed',
theme: 'classic',
backgroundColor: '#e5e5e5 #ccc',
title: {
text: 'Sales Comparison 2018 vs 2019',
backgroundColor: '#555',
},
plot: {
barsOverlap: '55%',
},
plotarea: {
margin: '80px 60px 35px 60px',
},
scaleX: {
values: [
'Jan',
'Feb',
'Mar',
'Apr',
'May',
'Jun',
'Jul',
'Aug',
'Sept',
'Oct',
'Nov',
'Dec',
'Jan',
'Feb',
'Mar',
'Apr',
'May',
'Jun',
],
guide: {
visible: false,
},
item: {
fontColor: '#333',
},
lineColor: '#db0a0a',
lineWidth: '3px',
tick: {
lineColor: '#db0a0a',
lineWidth: '3px',
placement: 'outer',
size: '8px',
},
},
scaleX2: {
values: [
'MR 1',
'MR 2',
'MR 3',
'MR 4',
'MR 5',
'MR 6',
'MR 7',
'MR 8',
'MR 9',
'MR 10',
'MR 11',
'MR 12',
],
guide: {
lineColor: '#333',
visible: true,
},
item: {
fontColor: '#555',
},
itemsOverlap: true,
label: {
text: 'Marketing Report',
fontColor: '#333',
},
lineColor: '#07be07',
lineWidth: '3px',
tick: {
lineColor: '#07be07',
lineWidth: '3px',
placement: 'outer',
size: '8px',
},
},
scaleY: {
values: '0:100:20',
guide: {
visible: false,
},
item: {
padding: '5px',
fontColor: '#333',
},
label: {
text: 'Number of New Clients Acquired',
fontColor: '#333',
offsetX: '8px',
},
lineColor: '#db0a0a',
lineWidth: '3px',
tick: {
lineColor: '#db0a0a',
lineWidth: '3px',
placement: 'outer',
size: '8px',
},
},
scaleY2: {
values: '0:8000:2000',
guide: {
lineColor: '333',
lineStyle: 'solid',
visible: true,
},
item: {
padding: '5px',
fontColor: '#333',
},
label: {
text: 'Marketing Dollars Spent',
fontColor: '#333',
},
lineColor: '#07be07',
lineWidth: '3px',
multiplier: true,
tick: {
lineColor: '#07be07',
lineWidth: '3px',
placement: 'outer',
size: '8px',
},
},
series: [
{
type: 'bar',
text: '2017 Sales',
values: [
36, 30, 20, 41, 26, 21, 23, 34, 21, 21, 15, 35, 29, 31, 15, 17, 21, 26,
],
tooltip: {
text: 'Number of New Clients<br>Acquired In %k 2018<br>%v',
},
backgroundColor: '#595959 #777',
hoverState: {
visible: false,
},
zIndex: 1,
},
{
type: 'bar',
text: '2018 Sales',
values: [
42, 24, 28, 36, 34, 28, 21, 19, 18, 22, 26, 24, 29, 30, 29, 19, 17, 20,
],
tooltip: {
text: 'Number of New Clients<br>Acquired In %k 2019<br>%v',
},
backgroundColor: '#db0a0a #ed0909',
hoverState: {
visible: false,
},
zIndex: 2,
},
{
type: 'line',
text: '2018 Marketing',
values: [
4470, 6300, 4590, 4500, 5550, 6500, 4775, 4950, 4400, 4100, 4800, 5100,
],
tooltip: {
text: 'Marketing Dollars Spent<br>Per Report %k 2019<br>$%v',
},
aspect: 'spline',
lineColor: '#07be07',
marker: {
backgroundColor: '#07be07',
borderColor: 'fff',
borderWidth: '1px',
size: '4px',
},
scales: 'scale-x-2, scale-y-2',
zIndex: 4,
},
{
type: 'line',
values: [
3650, 4000, 5150, 5150, 3800, 6100, 6800, 4000, 4030, 3100, 2090, 4100,
],
tooltip: {
text: 'Marketing Dollars Spent<br>Per Report %k 2018<br>$%v',
},
alpha: 0.5,
aspect: 'spline',
lineColor: '#595959',
marker: {
alpha: 0.5,
backgroundColor: '#595959',
borderWidth: '0px',
size: '4px',
},
scales: 'scale-x-2, scale-y-2',
},
],
};
// RENDER CHARTS
// -----------------------------
zingchart.render({
id: 'myChart',
data: chartConfig,
});