survey_by_demog: Survey microdata by race and sex

View source: R/microdata.R

survey_by_demogR Documentation

Survey microdata by race and sex

Description

Survey microdata by race and sex

Usage

survey_by_demog(
  df,
  var,
  weight_var = "PERWT",
  type = "categorical",
  geog = "FIPS",
  method = "default",
  other_grouping_vars = c(),
  breakdowns = c("total", "sex", "race", "sex_by_race")
)

Arguments

var

A column name to perform svymean on. Make sure the column name is in "".

weight_var

weight variable

type

Either mean or categorical

geog

geographic column

other_grouping_vars

other variables to group by

survey

A survey object containing FIPS, year, and optional race and sex columns.


greaterlouisvilleproject/glptools documentation built on Feb. 9, 2025, 11:21 a.m.