manipulateSqlPull: This function performs the manipulation of the sql extract...

Description Usage Arguments Details Value Examples

View source: R/functions.R

Description

This function performs the manipulation of the sql extract data; should be generic for any of the feature types

Usage

1
manipulateSqlPull(tmp_fv, flags, timeDiff)

Arguments

tmp_fv

Pull from sql query. Should have a column for date and concept_id

flags

Flags set in settings - specifies which normalization is needed

timeDiff

Value to use for normalization

Details

This is just a helper function that reduces the repeats of code for the manipulation of the sql extract data, so that it is put in the desired format for compiling all patient features together. This function: gets the counts of codes on a given visit (so multiple codes/terms/drugs/etc are not all counted); normalizes based on the normalization setting; returns a data frame with counts of codes

Value

An object containing the re-formatted patient data: ptID x (num concept IDs) - filled with counts, deduplicated by visit

Examples

1
2
3
4
5
6
## Not run: 

 test1 <- manipulateSqlPull(tmp_fv, flags, timeDiff)


## End(Not run)

OHDSI/Aphrodite documentation built on Sept. 18, 2020, 10:26 p.m.