Hi again,
From your second screenshot, you can see that thereās an error from the red colored message that appeared at the bottom of the window.
In programming, compilers (what translate your code into machine code) will most of the time indicate where your error is located and why.
It says :
mammals.csv does not exist or could not be read
NullPointerException
So the file clearly doesnāt exist!
First letās look at what the loadTable()
function takes as arguments :
loadTable(filename)
filename String: name of a file in the data folder or a URL.
options String: may contain āheaderā, ātsvā, ācsvā, or ābinā separated by commas
So the first parameter must be the path of an existing file on your computer (here we want a .csv file). Here āexistingā is important because otherwise the program canāt load it.
Now in Processing, when you indicate a path itās supposed to be in a data
folder inside your sketch folder, where your Processing code is located if you saved your project.
So are you sure that you have a mammals.csv
file in a data
folder in the sketch folder? To see it, you can go in the options Sketch -> Go to sketch folder
.
Note : this is the second post, see the first one : Where is the directory to save your .csv data?