| person | R Documentation |
Include disability, mobility, and other demographic categorical and numeric variables.
person
A data frame with 99564 rows (each row is a person) and 32 columns
Household identifier. Use this variable to join the person dataset and the house dataset. Use both this variable and person_id to join the person dataset and the trip dataset.
Person identifier. Use both this variable and household_id to join the person dataset and the trip dataset.
How long the respondent has had a medical condition that makes it difficult to travel outside of home. Values include 6_months_or_less_disability, More_than_6_months_of_disability, Lifelong_disability, and No_disability.
Sex of the respondent. Values include Male and Female.
Race of the respondent. Values include White, Black, Asian, American Indian, Hawaiian/Pacific Islander, Multiracial, and Other.
Hispanic or Latino origin. Values include Hispanic and Non-Hispanic.
Born in United States. Values include Yes and No.
Age of the respondent. Filtered to ages 18 to 61.
Educational attainment. Values include Less than a high school graduate, High school graduate or GED, Some college or associates degree, Bachelor's degree, and Graduate degree or professional degree.
Opinion of health. Values include Excellent, Very good, Good, Fair, and Poor.
Primary activity in previous week. Values include Employed and Unemployed.
Household income. Values include Under $10,000, $10,000 to $34,999, $35,000 to $74,999, $75,000 to $149,999, and $150,000 and over.
Count of household members. Values include Lives alone and Does not live alone.
Category of population density (persons per square mile) in the census block group of the household's home location. Values include 0-99, 100-499, 500-999, 1,000-1,999, 2,000-3,999, 4,000-9,999, 10,000-24,999, and 25,000 and over.
Household in urban or rural area. Values include Urban and Rural.
Household state. Includes the 50 states and Washington, DC.
Driver status. Values include Drives and Does not drive.
Does the respondent use a cane to aid their travel?
Does the respondent use a manual wheelchair to aid their travel?
Does the respondent use a crutch to aid their travel?
Does the respondent use a dog to aid their travel?
Does the respondent use a motorized wheelchair to aid their travel?
Does the respondent use a scooter to aid their travel?
Does the respondent use a white cane to aid their travel?
Does the respondent use a walker to aid their travel?
Derived from the original W_NONE variable. Indicates whether no listed mobility aid was reported.
Miles personally driven in all vehicles. Values range from 0 to 200000.
Count of public transit usage in last month. Values range from 0 to 30.
Count of rideshare app usage in last month. Values range from 0 to 99.
Count of bike trips in past week. Values range from 0 to 99.
Count of walk trips in past week. Values range from 0 to 200.
Count of times purchased online for delivery in last 30 days. Values range from 0 to 99.
if (require("tidyverse")) {
# Summary statistics of public transit use by travel disability status
transit_summary <- person |>
group_by(travel_disability) |>
summarize(
people = n(),
public_transit_users = sum(count_of_public_transit_usage > 0),
public_transit_use_prop = mean(count_of_public_transit_usage > 0),
public_transit_usage_median = median(count_of_public_transit_usage),
public_transit_usage_mean = mean(count_of_public_transit_usage),
public_transit_usage_sd = sd(count_of_public_transit_usage)
)
# Test whether public transit use differs by travel disability status
prop.test(
x = transit_summary$public_transit_users,
n = transit_summary$people
)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.