6

First time using the OpenFDA API.

It seems like wildcards are not permitted in queries, so I was curious how one might go about generating data such as the count of specific AEs by generic_name of the medication?

2 Answers 2

4

You cannot do a two-way table where you get a list of adverse events by drug using the current openFDA API.

What you can do is find most of* this information in a two step process which can of course be automated:

  1. Get a list of drugs by generic name: https://api.fda.gov/drug/event.json?search=&count=patient.drug.openfda.generic_name.exact&limit=1000
  2. Get a list of adverse events that have shown up in event reports that contained that generic drug. For example, ASPIRIN: https://api.fda.gov/drug/event.json?search=patient.drug.openfda.generic_name.exact:ASPIRIN&count=patient.reaction.reactionmeddrapt.exact&limit=1000

* "most of" because these count queries will return only the top 1000 results

Hope this helps!

1

Another route if your looking for a quick way to research is search the generic name on researchae.com then look at the stats tab and graphs for more detailed counts. For example a search of the generic name for Coreg results the following:

http://www.researchae.com/drugevent?from_date=2004-01-01&to_date=2014-11-30&from_age=&to_age=&search=&country=GLOBALLY&patientsex=&manufacturername=&drugbrandname=&druggenericname=carvedilol&medicinalproduct=&reactionmeddrapt=&drugclass=&drugindication=&indsubmit=&productndc=&safetyreportid=

Remember though there are different ways to search and you might want to add some additional filter to get to the data you are looking for.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.