My code is now working!
Code
float myValue;
int index; // The global index variable
String[] time;
String[] heart;
String[] speed;
void setup(){
size (1200, 1000);
frameRate(10);
time = loadStrings("time.csv");
heart = loadStrings("heart_rate.csv");
speed = loadStrings("speed.csv");
}
void draw(){
float a = new Float(speed[index]);
line(index * 10, a * 100, a * 50, a * 50);
myValue = 10 * (new Float(time[index]));
ellipse(index * 10, myValue * 20, myValue * 5, myValue * 5);
index++; // Check when reaching 120, stop or restart at 0
}
Sort of, anyway, need to get it to loop once index hits 120.