search for: kids_province_sum

Displaying 1 result from an estimated 1 matches for "kids_province_sum".

Did you mean: kids_province_sums
2018 Mar 19
1
Labelling a fortified GADM map plotted with ggplot and geom_map
...the year 2018 # extract the needed data kids_province_data <- data.table::data.table(kids_data_2017$Province_Territory__c, kids_data_2017$Number_of_kids__c) names(kids_province_data)[1] <- "Province" names(kids_province_data)[2] <- "Number" # sum the data by province kids_province_sums <- aggregate(.~Province, data = kids_province_data, sum) # join the data to the map names(tract)[6] <- "region" names(kids_province_sums)[1] <- "region" by_province <- left_join(tract, kids_province_sums) # create the data map kids_map <- ggplot(by_province, ae...