earthquakes icon

Earthquakes Python Library

From the CORGIS Dataset Project

By Ryan Whitcomb
Version 2.0.0, created 6/7/2016
Tags: earthquakes, nature, disaster, magnitude, richter scale, latitude, longitude

Overview

Earthquake records from around the world collected from the United States Geological Survey. Important details about the earthquake such as distance, gap, magnitude, depth and significance are included to properly describe the earthquake. Additionally, data about exact geological coordinates and a relative description of the earthquake’s location is included. The earthquakes collected are from the past month.

http://earthquake.usgs.gov/earthquakes/

Explore Structure

Each row represents $MISSING_FIELD.

Index Type Example Value
0 dict { }
1 dict (same structure)
2 dict (same structure)
... ... ...
Key Type Example Value Description
"id" str "nc72666881" The unique name for this earthquake.
"impact" dict { }
"location" dict { }
"time" dict { }
Key Type Example Value Description
"gap" float 122.0 In general, the smaller this number, the more reliable is the calculated horizontal position of the earthquake. Specifically, this means the largest azimuthal gap between azimuthally adjacent stations (in degrees). Earthquake locations in which the azimuthal gap exceeds 180 degrees typically have large location and depth uncertainties. Ranges from 0 to 180.
"magnitude" float 1.43 Earthquake magnitude is a measure of the size of an earthquake at its source. It is a logarithmic measure. At the same distance from the earthquake, the amplitude of the seismic waves from which the magnitude is determined are approximately 10 times as large during a magnitude 5 earthquake as during a magnitude 4 earthquake. The total amount of energy released by the earthquake usually goes up by a larger factor; for many commonly used magnitude types, the total energy of an average earthquake goes up by a factor of approximately 32 for each unit increase in magnitude. Typically ranges from -1 (very tiny) to 10 (incredibly powerful).
"significance" int 31 A number describing how significant the event is. Larger numbers indicate a more significant event. This value is determined on a number of factors, including magnitude, maximum MMI, felt reports, and estimated impact. Ranges from 0 to 1000.
Key Type Example Value Description
"depth" float 15.12 Depth of the event in kilometers.
"distance" float 0.1034 The rough distance that this earthquake occurred away from the reporting station, measured in degrees between. 1 degree is approximately 111.2 kilometers. In general, the smaller this number, the more reliable is the calculated depth of the earthquake. In general, this number is between 0.4-7.1.
"full" str "13km E of Livermore, California" The full name of this location.
"latitude" float 37.6723333 Decimal degrees latitude (up and down on the globe). Negative values for southern latitudes. Ranges from -90 to 90.
"longitude" float -121.619 Decimal degrees longitude (east and west on the globe). Negative values for western latitudes. Ranges from -180 to 180.
"name" str "California" A best guess for the name of the state (or country, in some cases) that this earthquake was reported in.
Key Type Example Value Description
"day" int 27 Day of the month for this earthquake.
"epoch" int 1469593183550 A number that represents the time that this earthquake occurred. Epoch's are the number of seconds since a particular date (January 1st, 1970), and are a convenient way to store date/times.
"full" str "2016-07-27 00:19:43" The full date/time representation for when this earthquake occurred.
"hour" int 0 The hour that this earthquake occurred.
"minute" int 19 The minute that this earthquake occurred.
"month" int 7 The month that this earthquake occurred.
"second" int 43 The second that this earthquake occurred.
"year" int 2016 The year that this earthquake occurred.

Downloads

Download all of the following files.

  1. earthquakes.py
  2. earthquakes.data

Usage

import earthquakes
earthquake = earthquakes.get_earthquake()

Documentation

get_earthquake()
Returns a list of dictionaries representing earthquake.