Vetahealth Charts - Pattern Sample

This is a Pattern Based Samples that can be used as samples.

by shivkumarganesh

HTML

<script src="https://code.jquery.com/jquery-2.2.4.min.js"></script>
<script src="https://code.highcharts.com/highcharts.js"></script>
<script src="https://highcharts.github.io/pattern-fill/pattern-fill.js"></script>

<div id="container" style="height: 300px"></div>

JavaScript

var gfxPath = 'https://sampleproject-shivkumarganesh.c9users.io/img/';



var chart = new Highcharts.Chart({

  chart: {
    renderTo: 'container'
  },

  title: {
    text: 'Pattern fill plugin demo'
  },

  xAxis: {
    categories: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec']
  },

  yAxis: {
    plotBands: [{
      from: 100,
      to: 200,
      color: {
        pattern: gfxPath + 'Bricks.png',
        width: 6,
        height: 6
      }
    }]
  },

  series: [{
    type: 'area',
    data: [29.9, 71.5, 106.4, 129.2, 144.0, 176.0, 135.6, 148.5, 216.4, 194.1, 95.6, 54.4],
    fillColor: {
      pattern: gfxPath + 'Dots_Large.png',
      width: 6,
      height: 6
    }
  }, {
    type: 'column',
    data: [148.5, 216.4, 194.1, 95.6, 54.4, 29.9, 71.5, 106.4, 129.2, 144.0, 176.0, 135.6],
    color: {
      pattern: gfxPath + 'Dots_Tiny.png',
      width: 8,
      height: 8,
      // VML only:
      color1: 'red',
      color2: 'yellow'
    }
  }]

});