Closed pegli closed 8 years ago
@pegli thanks for the contribution! Left a couple small questions on the code. From a cursory look, it's not obvious to me why the NaNs are being returned. I can merge it without fixing the NaNs though, as its still an improvement without.
I fixed the style issues you raised but haven't yet had the time to try to figure out the NaN issue.
Looks good, merging this.
I had some trouble with the JavaStocks sample using Spark 1.6. Initially, the sample app would throw an exception while parsing the dates for the DateTimeIndex:
I grabbed the index creation code from the Scala version to fix that, then ran into a problem with the Comparators that are used to get
max
andmin
fromdwStats
:I added a new class that implements both Comparator and Serializable and used that to sort the stats results. At this point, the demo runs but gives min and max results of
(AAL,NaN)
. The Scala demo gives the correct results. I'll update the PR if I can figure out why the Java version isn't working properly.