Riga 566: | Riga 566: | ||
<script> | <script> | ||
+ | function get_diff(vect){ | ||
+ | var vdiff = []; | ||
+ | vdiff.push(0); | ||
+ | for (var i=1;i<vect.length;i++){ | ||
+ | vdiff.push(vect[i]-vect[i-1]); | ||
+ | } | ||
+ | |||
+ | return vdiff; | ||
+ | } | ||
// ITA | // ITA | ||
Plotly.d3.csv('https://raw.githubusercontent.com/pcm-dpc/COVID-19/master/dati-andamento-nazionale/dpc-covid19-ita-andamento-nazionale.csv', function(err, rows){ | Plotly.d3.csv('https://raw.githubusercontent.com/pcm-dpc/COVID-19/master/dati-andamento-nazionale/dpc-covid19-ita-andamento-nazionale.csv', function(err, rows){ |