Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

visualize_df_by_race_ethnicity_party

Create box plots to visualize race and ethnicity by party


Description

Requires a data.frame with specific column names. In practice, the data.frame is expected to come from a function like ?get_congressional_districts and then merged with a data.frame that has column "party".

Usage

visualize_df_by_race_ethnicity_party(df)

Arguments

df

A data.frame with columns "party", "percent_white", "percent_black", "percent_asian", "percent_hispanic"

Examples

data("df_congress116_demographics")
data("df_congress116_party")
df = merge(df_congress116_demographics, df_congress116_party)
# Race and Ethnicity of the 116th Congressional Districts using data from
# the 2018 5-year American Community Survey
visualize_df_by_race_ethnicity_party(df)

choroplethr

Simplify the Creation of Choropleth Maps in R

v3.7.0
BSD_3_clause + file LICENSE
Authors
Ari Lamstein [aut, cre], Brian Johnson [ctb], Trulia, Inc. [cph]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.