Skip to content

Functions to extract drug records from the FAERS (FDA Adverse Event Reporting System) database

License

Notifications You must be signed in to change notification settings

tystan/fuzzyfaers

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

32 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

The fuzzyfaers package

Functions to extract drug records from the FAERS (FDA Adverse Event Reporting System) data in a postgreSQL database for analysis in R.

As drug names (whether they be generic/clinical or branded) are provided to the FDA and do not undergo standardisation, this package provides an automated way to extract records of a drug, its synonyms and their inevitable misspellings (plus superfluous text). Fuzzy string matching is required to do this, thus, fuzzyfaers.

Background and motivation

Signal detection of adverse drug events often requires analysis of tabulated count data as seen in the below table.

Event(s) X Event(s) Y
Drug(s) A a b
Drug(s) B c d

To get to this data, or a flat dataset with a single record for each adverse event is a time consuming process. Not only that but finding synonyms to drug names is a painfully manual process, compounded by alternative spellings and superfluous text included in the drug text fields.

This package aims to

  1. provide data in as ready-to-go format as possible with instructions to house it in a manageable database environment accessible by R, and
  2. automate the drug synonym (and misspelling) searching in the database to extract single record adverse event data.frames in R.

Prerequisites

All required software are free and available on Linux, Mac OS and Windows. Testing has been undertaken on Ubuntu LTS 18.04 and Windows 10 systems. You will likely need ~10Gb of disk space for the database/data installation and enough memory to deal with data.frames in R potentially with millions of records (I have found 32Gb of memory sufficient for me).

Example usage

library(devtools) # see https://www.r-project.org/nosvn/pandoc/devtools.html
devtools::install_github('tystan/fuzzyfaers')
library(fuzzyfaers)
### see help file to run example

fuzzyfaers process to extact drug specific FAERS data

About

Functions to extract drug records from the FAERS (FDA Adverse Event Reporting System) database

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published