extractRauchstatus: get data about smoking behavior from the table FRM_BAS

View source: R/extractRauchstatus.R

extractRauchstatusR Documentation

get data about smoking behavior from the table FRM_BAS

Description

get data about smoking behavior from the table FRM_BAS

Usage

extractRauchstatus(
  FRM_BAS,
  rauchvars = c("RAUCHJAHRE", "RAUCHPACK", "RAUCHAKT", "RAUCHL12M")
)

Arguments

FRM_BAS

data.table containing the table FRM_BAS from the database of the PROGRESS study

rauchvars

a character vector with the names of the variables to be extracted.

Value

a data.table with the PATSTUID and the extracted patient characteristics.

Examples

## Not run: 
excel_fn <- paste0("/net/ifs1/san_projekte/projekte/",
"PROGRESS/Datenmanagement/Data_freezes/",
"20190320/PROGRESS-freeze_201903_01.xlsx")
FRM_BAS <- readxl::read_excel(excel_fn, "FRM_BAS")
data.table::setDT(FRM_BAS)
extractRauchstatus(FRM_BAS, rauchvars = "RAUCHL12M")
extractRauchstatus(FRM_BAS, rauchvars = c("RAUCHL12M", "RAUCHJAHRE"))

## End(Not run)

maciejrosolowski/progressdatenbankderivate documentation built on Nov. 29, 2024, 3:39 a.m.