pull_rx_encounters: Pull rx encounters across multiple years

pull_rx_encountersR Documentation

Pull rx encounters across multiple years

Description

This function pulls columns from a specified table

Usage

pull_rx_encounters(
  years,
  medicaid_years,
  ndc_codes,
  vars = c("enrolid", "ndcnum", "svcdate"),
  num_to_collect = 10,
  cluster_size = 20,
  db_path = "/Shared/Statepi_Marketscan/databases/Truven/"
)

Arguments

years

vector of years to collect. Note: if no argument is provided all years will be selected

medicaid_years

years of medicaid data to collect for

ndc_codes

ndc codes to pull

vars

vector of variables to collect

num_to_collect

the number of variables to collect

cluster_size

size of cluster to create for pulling data

db_path

path to Truven databases


aarmiller/dbBuildr documentation built on Jan. 29, 2024, 5:36 a.m.