extractDiagnoses: Extract diagnoses

Description Usage Arguments Value

Description

Extracts patient diagnoses from the Diamonds database and returns a data frame.

Usage

1
2
extractDiagnoses(connection, diagnoses = NULL, patients = NULL,
  format = "raw", n = -1)

Arguments

connection

ODBC connection object returned by dbConnect.

diagnoses

A character vector of ICD9 or ICD10 codes. If no limit is desired then set as NULL. May use % or _ for partial matches.

patients

A character vector of patient medical record numbers. If no limit is desired then set as NULL.

format

A character vector indicating the output format. Options include "raw" or "byDiagnosis".

n

Number of records to retrieve. Use n = -1 to retrieve all records.

Value

Returns a data frame with patient diagnoses and the date they were assigned in the Diamonds database.


davidcoffey/Diamonds documentation built on June 23, 2019, 7:43 a.m.