Learn R Programming

Lock5withR (version 1.2.2)

USStates: US State Data

Description

Various data for all 50 US States

Arguments

Format

A data frame with 50 observations on the following 17 variables.
  • State Name of state
  • HouseholdIncome Mean household income (in dollars)
  • IQ Mean IQ score of residents
  • McCainVote Percentage of votes for John McCain in 2008 Presidential election
  • Region Area of the country: MW=Midwest, NE=Northeast, S=South, or W=West
  • ObamaMcCain Which 2008 Presidential candidate won state? M=McCain or O=Obama
  • Pres2008 Which 2008 Presidential candidate won state? M=McCain or O=Obama
  • Population Number of residents (in millions)
  • EighthGradeMath a numeric vector
  • HighSchool Percentage of high school graduates
  • GSP Gross State Product (dollars per capita)
  • FiveVegetables Percentage of residents who eat at least five servings of fruits/vegetables per day
  • Smokers Percentage of residents who smoke
  • PhysicalActivity Percentage of residents who have competed in a physical activity in past month
  • Obese Percentage of residents classified as obese
  • College Percentage of residents with college degrees
  • NonWhite Percentage of residents who are not white
  • HeavyDrinkers Percentage of residents who drink heavily

Source

Various online sources, mostly at www.census.gov

Examples

Run this code

data(USStates)

Run the code above in your browser using DataLab