Plotly javascript csv without headers


#1

hi!

i have a csv file with this structure:

2018-05-15T15:53:01,500,890,390,0
2018-05-15T15:54:01,500,890,390,0
2018-05-15T15:55:01,500,890,390,0
2018-05-15T15:56:01,500,890,390,0
2018-05-15T16:00:01,500,890,390,0
2018-05-15T16:06:01,500,890,390,0

i don’t have the csv headers, but know what each row means.
how can i create a chart with no headers using javascript.

example:

    Plotly.d3.csv("http://localhost:3000/beca8dafb525283e38c7dc6e58da0b2dfd53c5310a6af2e333794123b338ae8a", function(err, rows){
function unpack(rows, key) {
return rows.map(function(row) { return row[key]; });
}
var Ayes = {
type: "scatter",
mode: "lines",
name: 'Absolute Yes',
x: unpack(rows, '**Date**'),  //row1 Date
y: unpack(rows, '**Ayes**'),  /row2   Value
line: {color: 'green'}
}