Here is the R code for the competition entry mentioned in my previous post. See http://www.datamilk.com/leaderboard_animation.gif for the animation. library ( lubridate ) library ( plyr ) library ( sqldf ) library ( ggplot2 ) library ( animation ) #clear everything rm ( list = ls ( all = TRUE ) ) # Injest data data <- read.csv ( "unimelb_public_leaderboard.csv" , header= TRUE ) # calculate days and date time as numeric data <- data.frame ( data , SubmissionDate_datetime = strptime ( data $SubmissionDate , format = "%m/%d/%Y %H:%M:%S %p" ) , Submission_day = round ( strptime ( data $SubmissionDate , format = "%m/%d/%Y %H:%M:%S %p" ) , "day" ) , Submission_time_num = as.numeric ( strptime ( data $SubmissionDate , format = "%m/%d/%Y %H:%M:%S %p" ) ) ) start_time <- min ( na.omit ( data $SubmissionDate_datetime ) ) end_time <- max ( na.omit ( data $SubmissionDate_datetime ) ) s...
Posts
Showing posts from February, 2013