newsdev/nyt-docket

Name: nyt-docket

Owner: NYT Newsroom Developers

Description: A Python client for parsing SCOTUS cases from the granted/noted and orders dockets. https://pypi.python.org/pypi/nyt-docket

Created: 2015-10-04 23:44:31.0

Updated: 2018-05-23 02:17:33.0

Pushed: 2017-09-28 19:12:18.0

Homepage:

Size: 25

Language: Python

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

Getting started
install nyt-docket
Using nyt-docket
Command-line interface
et grants 2015
et orders 2015
et opinions 2015
Demo app

Run the demo app.

on -m docket.demo
Modules

Use the docket loader manually from within your Python script.

Grants (new cases)

Grants are cases that have been granted certiorari and will be heard by the Court in this term. The most interesting thing about a grant, besides its existence, is the question the Court will be deciding. This is associated as a separate PDF file on the Court's site but the parser attaches it to the case as a text blob.

 docket import grants

grants.Load()
rape()

case in g.cases:
print case.__dict__
Slip opinions (decisions)

Slip opinions are decisions in cases the Court has either heard arguments on or has made a procedural decision on. These opinions are not final, but it's the fastest way to know when the Court has acted on a case. The most important feature of a slip opinion is the opinion text, which is a separate PDF file. This is associated with the opinion as a hyperlink.

 docket import slipopinions

slipopinions.Load()
rape()

case in o.cases:
print case.__dict__
Orders (all kinds of things)

Orders are the daily business of the Court. Denials of certiorari as well as various other procedural motions are resolved in the orders list. This plugin grabs the long orders list itself as a PDF link and then parses it out into individual cases. WARNING: The individual cases rely on regex and tomfoolery. The methods for parsing them are fragile, so YMMV.

 docket import orders

orders.Load()
rape()
rse()

order in z.orders:
print order.__dict__

case in z.cases:
print "%s\t%s\t%s" % (case.docket, case.orders_type, case.casename)

This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.