Extraction and Management of Clinical Practice Research Datalink Data


[Up] [Top]

Documentation for package ‘rcprd’ version 0.0.1

Help Pages

add_to_database Adds a single .txt file to an SQLite database on the hard disk.
combine_query Combine a database query with a cohort.
combine_query.aurum Combine a CPRD aurum database query with a cohort.
combine_query_boolean Combine a database query with a cohort returning a 0/1 vector depending on whether each individual has a recorded code of interest.
combine_query_boolean.aurum Combine a CPRD aurum database query with a cohort returning a 0/1 vector depending on whether each individual has a recorded code of interest.
connect_database Open connection to SQLite database
cprd_extract Adds all the .txt files in a directory, with certain file names, to an SQLite database on the hard disk.
create_directory_system Create the appropriate directory system to be able to run functions without specifying hard filepaths
db_query Query an RSQLite database.
delete_directory_system Deletes directory system created by 'delete_directory_system'
extract_bmi Extract most recent BMI score relative to an index date.
extract_cholhdl_ratio Extract most recent total cholesterol/high-density lipoprotein ratio score relative to an index date.
extract_cohort Create cohort from patient files
extract_diabetes Extract diabetes status prior to an index date.
extract_ho Extract a 'history of' type variable
extract_smoking Extract smoking status prior to index date.
extract_test_data Extract test data.
extract_test_data_var Extract standard deviation of all test data values over a specified time period relative to an index date.
extract_test_recent Extract test data.
extract_time_until Extract a 'time until' type variable
extract_txt_char Read in txt file with all colClasses = "character"
extract_txt_cons Read in raw .txt consultation file
extract_txt_death Read in raw ONS death data file
extract_txt_drug Read in raw .txt drugissue file
extract_txt_hes_primary Read in raw HES primary diagnoses file
extract_txt_linkage Read in linkage eligibility file
extract_txt_obs Read in raw .txt observation file
extract_txt_pat Read in raw .txt patient file
extract_txt_prob Read in raw .txt problem file
extract_txt_ref Read in raw .txt referral file
implement_output Internal function to implement saving extracted variable to disk or returning into R workspace.