Generates sum of new members between each meetup.

new_mem_counter(data)

Arguments

data

A data.frame created by exporting the members list from meetup.com. Note: All date fields must by coverted to class Date.

Value

new_mem_counter returns a data.frame containing 2 variables. These are the `Date` of each meetup, and how many `New` members joined leading up to each meetup.

Examples

data(member_list) new_members <- new_mem_counter(member_list) tail(new_members)
#> Date New #> 66 2018-11-14 52 #> 67 2019-01-23 65 #> 68 2019-02-27 50 #> 69 2019-03-20 19 #> 70 2019-05-15 66 #> 71 2019-06-13 16
# Plot the new members data since 2017. # Create Date Range Index Range <- new_members[new_members$Date > "2017-01-01" & new_members$Date <= Sys.Date(),] Date_Index <- as.numeric(row.names(Range)) # Create x-axis labels, using year-month date format x_labels <- format(new_members$Date[Date_Index], "%Y-%m") # Plot barplot(new_members$New[Date_Index], names.arg = x_labels, las=2, main = "CRUG members, joined between meetups", ylab = "New Members", xlab = "")