July 2017
Intermediate to advanced
796 pages
18h 55m
English
In the previous section, we have seen how to load, parse, manipulate, and query the DataFrame. Now it would be great if we could show the data for better visibility. For example, what could be done for the airline carriers? I mean, is it possible to find the most frequent carriers from the plot? Let's give ggplot2 a try. At first, load the library for the same:
library(ggplot2)
Now we already have the SparkDataFrame. What if we directly try to use our SparkSQL DataFrame class in ggplot2?
my_plot<- ggplot(data=flightDF, aes(x=factor(carrier)))>>ERROR: ggplot2 doesn't know how to deal with data of class SparkDataFrame.
Obviously, it doesn't work that way because the ggplot2 function doesn't know how to deal ...
Read now
Unlock full access