Giter Club home page Giter Club logo

clinical_trials_python's Introduction

Clincal Trials Python API

A Python API wrapper for the ClincalTrials.gov API.

Documentation for ClinicalTrials.gov can be found here.

Usage

The Trials class only has two methods -- search and download. The same information from search is returned to the download method in ZIP file format.

>>> from clinical_trials import Trials
>>> t = Trials()
>>> t.search("alzheimer's disease")

>>> t.search('diabetes', 'cond')
>>> t.search('diabetes', 'condition')
>>> t.search(condition='diabetes')

>>> # Specify the number of trials turned.
... t.search(intervention='Fluoxetine', count=200)

>>> # Find trials no longer recruiting.
... t.search('lyme disease', recruiting='closed')

>>> # If you want plain XML returned back.
... t.search(sponsor='NHLBI', output_format=None)

>>> # You can also find trials by location -- up to 3 states or countries.
... t.search('cancer', state='TX')

>>> t.search('diabetes', state1='TX', state2='NY', state3='CA')
>>> t.search(condition='lyme disease', country1='US', country2='CA')

>>> # And you can download a ZIP file with the data.
... zip_file = t.download('cancer', count=500)

Copyright

Copyright (c) 2011 Code for America Laboratories.

See LICENSE for details.

clinical_trials_python's People

Contributors

zachwill avatar

Watchers

James Cloos avatar

Forkers

sachadev34fr

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.