Join Carlos Rivas for an in-depth discussion in this video Import the CSV, part of Code Clinic: Java.
- [Instructor] Before moving forward,…make sure you have the dashboard…starter project folder open,…and your favorite java IDE.…You can find it in starter projects.…Chapter six, there's the dashboard.…We're using visuals to decode,…so let's open it up and take a look.…Looking at our input file here,…we can see that it is comma separated,…and that it contains a time stamp…at increments in one second intervals.…Each one second data point contains…engine efficiency, red, green, blue values,…and the Pulsometer readout.…
Our job is to load all these values into several arrays…that we can later use from our API service method.…Let's switch over to our code now.…Lines 17 through 21 show the arrays…that will contain our data.…Let's now find our load data method and expand it.…In the while loop in line 41,…we read each line of the input file…into a string called data, which we then split by comma,…into an array of string tokens.…
This happens on line 44.…The following lines, 45 through 49,…convert the data into numbers,…and loads them into the array.…
Visit other courses in the series to see how to solve the exact same challenges in languages like C#, C++, PHP, Python, and Ruby.
Skill Level Intermediate
1. Problem 1: Pond Oreille
2. Problem 2: Where Am I?
3. Problem 3: Eight Queens
4. Problem 4: Accessing Peripherals
5. Problem 5: Facial Recognition
6. Problem 6: Real-Time Information Dashboard
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.