Overview

Medicare has collected data on many different hospitals throughout the country to allow users to compare the quality of these institutions before using their services. Data includes descriptions of the location of the hospitals, information about the hospitals' emergency services and type of hospital, and outpatient volume for the different wards of the hospitals.

https://data.medicare.gov/data/hospital-compare

Downloads

Download all of the following files.

Usage

Begin by adding the above JAR file to your classpath. This library has 1 function you can use.
import corgis.hospitals.HospitalsLibrary;
import corgis.hospitals.domain.*;
import java.util.ArrayList;

public class ExampleClass {
    public static void main(String[] args) {
        // Get access to the library
        HospitalsLibrary hospitalsLibrary = new HospitalsLibrary();
        // Access data inside the library
        ArrayList<Hospital> list_of_hospital = hospitalsLibrary.getHospitals(false);
    }
}
Additionally, some of the functions can optionally return Big Data using the last argument (setting it to true). If you use this Big Data, it may be much slower. Wait until you are sure your code is correct before using these examples.
import corgis.hospitals.HospitalsLibrary;
import corgis.hospitals.domain.*;
import java.util.ArrayList;

public class ExampleClass {
    public static void main(String[] args) {
        // Get access to the library
        HospitalsLibrary hospitalsLibrary = new HospitalsLibrary();
        // Access data inside the library
        ArrayList<Hospital> list_of_hospital = hospitalsLibrary.getHospitals(true);
    }
}

Documentation

We provide full JavaDoc for this library. Alternatively, you may refer to the below:

 hospitalsLibrary.getHospitals(test)

Returns hospitals from the dataset.