Created 03-29-2018 04:56 PM
I'm trying to run the zeppelin notebook for Data Science with Hadoop: Predicting Airline Delays – Part 2.
In the first paragraph I'm getting the java errors below - I assume that I'm not importing a class that I need but any help is greatly appreciated!
===============================================================================================
import org.apache.spark.rdd._
import scala.collection.JavaConverters._
import au.com.bytecode.opencsv.CSVReader
import java.io._
import org.joda.time._
import org.joda.time.format._
<console>:44: error: not found: type DateTime val sampleDate = new DateTime(year, month, day, 0, 0) ^
<console>:47: error: not found: value DateTimeFormat val holiday = DateTimeFormat.forPattern("MM/dd/yyyy").parseDateTime(c) ^
<console>:48: error: not found: value Days val distance = Math.abs(Days.daysBetween(holiday, sampleDate).getDays)
Created 03-31-2018 06:28 AM
I don't think you are missing an import statement. Looking at your code snippet, you have mentioned
import org.joda.time._ //DateTime and Days come from this import import org.joda.time.format._ //This import gives us DateTimeFormat
Please verify if you have mentioned all the import correctly. You should be able to use the aforementioned functions if such is the case.
Created 04-01-2018 04:07 PM
Did the answer help in the resolution of your query? Please close the thread by marking the answer as Accepted!
Created 04-02-2018 04:14 PM
Thanks for your response!
Yes, I have those import statements and it's still not working.