var apiURL= 'https://data.cityofnewyork.us/resource/kpav-sd4t.json';
var rows = [5, 440, 870];
var rows2 = [20, 480, 880];
dataStuff= loadJSON(apiURL);
titleFont= loadFont('BebasNeue-Regular.ttf');
txFont= loadFont('Barlow-Light.ttf');
createCanvas(windowWidth, windowHeight);
for(let i =jobIndex ;i<6;i++)
let y = cols2[floor(i/3)];
drawJobs('Agency: ', 'Buisness Title: ', 'Salary: ', dataStuff[i].agency, dataStuff[i].business_title, dataStuff[i].salary_range_from, x, y);
function drawJobs(description1, description2, description3, data1, data2, data3, hShift, vShift){
text(description1 + data1, hShift, vShift);
text(description2 + data2, hShift, vShift+30);
text(description3 + data1, hShift, vShift+60);
function drawSquares(horiziontalS, verticalS, Swidth, Sheight, r, g, b){
rect(horiziontalS, verticalS, Swidth, Sheight);
text('JOB OPPORTUNITIES IN NYC', width/2, 80);
let y = cols[floor(i/3)];
drawSquares(x, y, 390, 120, random(160, 255), random(70, 180) , random(55, 200));