title: How to draw a linear regression line in Chart.js
body: <p>I saw other libraries support this but there is very little data for Chart.js. Can anybody indicate me the way to start with a regression line for my graph? This is my code so far:</p>
  
  <pre><code>var datiedu3 = {"labels": ['ok'],
            "datasets": [{label: 'EEE',
                          data: datoa ,
  
                          backgroundColor: 'rgb(255, 99, 132)',
                          borderWidth: 1,
                          showLine: false}] 
             };
  
  function grafo2(dati, opzioni) {
    var grafoline = document.getElementById('Chartline').getContext('2d');
    new Chart(grafoline, {type: 'scatter',data: dati, options: opzioni});
  };
  // display the data used in dataset[0]:
  console.log(datiedu3.datasets[0].data)
  grafo2(datiedu3)
  </code></pre>
  
  <p>I figured I had to create another dataset with a line graph, and put my equation there, but I don't know how to do it and I'm a bit lost.</p>
  
  <p>My whole code is here <a href="https://codepen.io/dreamtheater96/pen/ZEGvRVj" rel="nofollow noreferrer">codepen</a></p>