From the course: Data Science for Java Developers

Unlock this course with a free trial

Join today to access over 22,600 courses taught by industry experts.

Loading CSVs

Loading CSVs

- [Illustrator] Okay. So, we've seen how to load data from a comma separated line by line data file, as in the case of our adult data here. And we've also seen how to load more of a tab separated or white space separated file, such as in the case of our auto MPG file here. So, the last example that we're going to take a look at here, just in terms of how to load data, is how to load CSV files. So, in order to just take a look at what a CSV file is, and how it differs from say the adult data that we looked at beforehand, open up the Groceries dataset.CSV file. So, you're going to notice something about this file, and that is that the actual names of the attributes are included at the top of it, right? That's a pretty standard CSV file format. And what we're going to do, is we're going to use a CSV library from the Apache Commons to actually load this data for us. So, the first thing you're going to want to do, is download the…

Contents