var yearEast, yearWest, discovery;
data = loadTable("discovery.csv","csv","header");
createCanvas(windowWidth, 6000);
yearEast = data.getColumn("East");
yearWest = data.getColumn("West");
discovery = data.getColumn("Discovery");
randomB = random(50,100);
for(var i=0;i<yearEast.length;i++) {
var yPosEast = map(yearEast[i],601,1976,100,5900);
var yPosWest = map(yearWest[i],601,1976,100,5900);
fill(randomHue,100,randomB);
text(yearEast[i],100,yPosEast);
stroke(randomHue,100,randomB);
ellipse(130,yPosEast,5,5);
text(discovery[i],150,yPosEast);
fill(randomHue,100,randomB);
text(yearWest[i],windowWidth-90,yPosWest);
stroke(randomHue,100,randomB);
ellipse(windowWidth-100,yPosWest,5,5);
line(130,yPosEast,windowWidth-100,yPosWest);
stroke(randomHue,100,randomB);
bezier(130,yPosEast,windowWidth/2,yPosEast,windowWidth/2,yPosWest,windowWidth-100,yPosWest);
randomHue = random(0,360);