get_data_death: Get Death microdata from storage.

View source: R/get_data.R

get_data_deathR Documentation

Get Death microdata from storage.

Description

Get Death microdata from storage.

Usage

get_data_death(
  cols = NA,
  year = NA,
  kingco = TRUE,
  version = "final",
  topcode = TRUE,
  mykey = "hhsaw",
  include_prelim = FALSE
)

Arguments

cols

Character vector of length >=1. Identifies which columns should be returned. NA returns all columns in the analytic dataset. See list_dataset_columns for more information on which columns are considered default by dataset.

Default = NA

year

Numeric vector. Identifies which years of data should be pulled. NA returns the most recent year.

Default = NA

kingco

logical. Return dataset for analyses where county of decedent's residence is King County.

Default = TRUE

version

Character vector of length 1. Either 'final' or 'stage'.

Default = 'final'

topcode

logical. Whether to top code chi_age at 100 to match population data.

Default = TRUE

mykey

Character vector of length 1. Identifies the keyring:: 'service' name that can be used to access the Health & Human Services Analytic Workspace (HHSAW).

Default == 'hhsaw'

include_prelim

logical. Whether to include preliminary data. WARNING: Keep as FALSE for production use. Preliminary data is incomplete and unsuitable for analysis.

Default = FALSE

Value

a single data.table

Examples



 test <- get_data_death(
          cols = c('chi_year', 'race4', 'chi_sex'),
          year = c(2019),
          kingco = TRUE,
          version = 'final',
          topcode = FALSE,
          mykey = 'hhsaw')

 head(test)


PHSKC-APDE/rads documentation built on April 14, 2025, 10:47 a.m.