/**
@serie : iris data set
@author: coyarzun@error404.cl
Distribución de datos en n columnas
*/
PFont font;
int fontsize = 12;
String[] file;
void setup(){
size(800,400);
font = loadFont("AndaleMono-12.vlw");
textFont(font, fontsize);
file = loadStrings("iris.data");
}
void draw(){
background(0);
fill(255);
text("IRIS RAW DATA", 2, fontsize);
//el numero de filas q tendrá cada columna
int rows = 30;
fill(0,255,255);
for (int i=0; i < file.length; i++){
//utilizamos las operaciones división y módulo para organizar los datos en x e y respectivamente
text(file[i], 2+(i/rows)*250, fontsize*(3+i%rows));
}
}