Creating a 3d globe with a line pin pointing a location on the globe to where myself and a fellow military person as deployed to. (me = army, him = air force). Right now we have the data being imported via a .csv file. Currently I can get all the points mapped on the globe via long and lat coordinates. My issue is the for loop to recognize the different. Right now a field is called ID, if ID = 1 then stroke color = blue, and if ID = 2, then stroke color is green. Currently the code colors all the lines as one color and doesn't recognize the other. Below are some snippits of the code to hopefully make things clear.
Greetings. I am just learning Processing and I am tasked with creating a simple bar graph from a set numbers from an xcel spreadsheet. I believe I just need like a for or an if loop to have it create a bar for each of the values (where the value would be the height of the bar).
Below is my code. Right now I get all the bars to show up, but seem to overlap one another.
int[] coords;
void setup() {
size(500,500);
background(255);
fill(200,200,30,50);
String[] nums = loadStrings("numbers.csv");
coords = int(split(nums[0], ','));
} // end setup
void draw() {
//sets location for each bar, 50 units apart
for (int x = 0; x < 500; x = x + 50) {
//creates a counter for each of the values in the array
for (int i = 0; i < 10; i = i + 1){
//draws the rectangle for each of the values in the array to corresponding height