knitr::opts_chunk$set(echo = TRUE)
library(tidyverse)
library(anytime)
library(lubridate)
library(RColorBrewer)
library(viridis)

Read In Posts and Comments

posts <- 
  read_csv("./data/reddit-analytics-posts-filtered.csv")
comments <- 
  read_csv("./data/reddit-analytics-comments-filtered.csv")

Comments on Posts

posts %>% 
  summarize(mean = mean(num_comments),
            sd = sd(num_comments),
            median = median(num_comments),
            min = min(num_comments),
            max = max(num_comments)
  )
## # A tibble: 1 × 5
##    mean    sd median   min   max
##   <dbl> <dbl>  <dbl> <dbl> <dbl>
## 1  7.82  7.98      5     1    41

Posts Voting

posts %>% 
  summarize(mean = mean(score),
            sd = sd(score),
            median = median(score),
            min = min(score),
            max = max(score)
  )
## # A tibble: 1 × 5
##    mean    sd median   min   max
##   <dbl> <dbl>  <dbl> <dbl> <dbl>
## 1  8.19  12.9      3     0    68

Comments Voting

comments %>% 
  summarize(mean = mean(score),
            sd = sd(score),
            median = median(score),
            min = min(score),
            max = max(score)
  )
## # A tibble: 1 × 5
##    mean    sd median   min   max
##   <dbl> <dbl>  <dbl> <dbl> <dbl>
## 1  3.72  7.21      2    -8    83