.us()
setScience("iradio", create=TRUE, subl=TRUE)
subProj <- "Desktop_vs_Mobile"

DT.iradioevents <- qGetAll("staging_raw_itunes_iradio_event")
DB.iradio.event <- DT.iradioevents
{if (identical(DB.iradio.event, DT.iradioevents)) {rm(DT.iradioevents)}}
jesusForData(DB.iradio.event, info="RawPull_2014Mar04")

========

are(DB.iradio.event)

idcol     :   customer_id,   apple_id,   station_id,   storefront_name
            
 factor    :   event_type,   end_reason,   device_type,   track_ownership,
               station_type
            
 integer   :   uniqTracks,   totalTracks
            
 numeric   :   Track.Seconds
            
 POSIXct   :   event_start_time,   event_end_time
            
 difftime  :   duration
            
 logical   :   SkippedBefore10,   SkippedBefore30

lib(ggplot2)


P.trks <- ggplot() + geom_boxplot(aes(y=totalTracks, x=device_type, color=end_reason), notch=TRUE, data=agg.tracks.per.device_type) + ggtitle("Total Tracks by Device Type & End-Reason")
P.trks + scale_y_log10(labels=comma)









