powered by
Function that returns the population pyramid of the municipality or department of a specific year
population_pyramid( divipola_code, year, sex = TRUE, range = 5, total = TRUE, plot = FALSE, language = c("EN", "ES") )
A dataframe with the proportion or total count of individuals
A code from the divipola table representing a department or municipality. To obtain values at the national level, code '0' is used
A numeric input for the year of interest
A boolean to consult data disaggregated by sex. The default value is TRUE
A numeric value from 1 to 100 for the age range to use. The default value is 5
A boolean for returning the total number rather than the proportion of the country's population. The default value is TRUE
A boolean for displaying a plot. The default value is TRUE
Language for plot components
population_pyramid("15001", 2015, sex = TRUE, total = TRUE, plot = TRUE)
Run the code above in your browser using DataLab