Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • -dstdize- to calculate average age-adjusted death rate by race

    Good Morning,

    I would like to calculate the average age-adjusted death rate by race (separately for whites and blacks), and test if the rates for countries are statistically different. As an example, I have modified Stata's mortality data file as follows:
    Code:
    clear
    input str6 nation byte age_category float(population deaths)
    input str6 nation byte age_category race_category float(population deaths)
    "Sweden" 1 1 3100000  3000
    "Sweden" 1 2 45000  523
    "Sweden" 2 1 3000000  10000
    "Sweden" 2 2 57000  928
    "Panama" 1 1 700000  300
    "Panama" 1 2 41000  904
    "Panama" 2 1 270000  1000
    "Panama" 2 2 75000  421
    end
    label values age_category age_lbl
    label def age_lbl 1 "0 - 29", modify
    label def age_lbl 2 "30 - 59", modify
    label values race_category race_lbl
    label def race_lbl 1 "White", modify
    label def race_lbl 2 "Black", modify
    Based on my understanding of the -dstdize- command, the following code will give me the average death rate by race for each country.
    Code:
    dstdize deaths population age_category, by(nation race_category)
    I have the following two questions:
    1. In my study, I have about 300 countries. Hence, I would like to present an age-adjusted rate for blacks and whites (averaged across all countries). I just want to make sure that the following code will help me achieve this?
    Code:
    dstdize deaths population age_category, by(race_category)
    2. Is there a way for me to test if the death rate for whites in Sweden is statistically different from that for whites in Panama?

    I am using Stata MP 14.2 for Windows.

    Many thanks in advance,
    Caroline

  • #2
    Good Morning Statlisters,

    I would greatly appreciate your advice on my question regarding the -dstdize- command that I posted yesterday.

    Thank you,
    Caroline

    Comment

    Working...
    X