title: How to create rectangles on canvas as in a graph (picture)
body: <p>Can you please tell me how to implement such a graph as in the example?
  I have the following test data:</p>
  <pre><code>[
  {
    day: 2,
    sum: 7799857
  },
  {
    day: 3,
    sum: 6986099      
  },
  {
    day: 4,
    sum: 6471975,
  },
  {
    day: 7,
    sum: 5895399,
  },
  {
    day: 8,
    sum: 5194120,
  },
  {
    day: 9,
    sum: 4851008,
  },
  {
    day: 10,
    sum: 4483119,
  },
  {
    day: 11,
    sum: 3492771,
  },
  {
    day: 14,
    sum: 2717263,
  },
  {
    day: 15,
    sum: 1763884,
  },
  {
    day: 16,
    sum: 1111772,
  },
  {
    day: 17,
    sum: 148788,
  },
  ...
  ];
  </code></pre>
  <p>I don’t really understand how to separate them (as in the graph, different rectangles)</p>
  <p>The chart looks like this
  <a href="https://i.stack.imgur.com/Q6njj.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Q6njj.png" alt="enter image description here" /></a></p>
  <p>I'll be glad for a hint.</p>