Catalog.from_quakeml#

classmethod Catalog.from_quakeml(quakeml: str, include_all_magnitudes: bool = True, include_uncertainties: bool = False, include_ids: bool = False, include_quality: bool = False) Catalog#

Create a Catalog from a QuakeML file.

Parameters:
  • quakeml – Path to a QuakeML file or QuakeML as a string.

  • include_all_magnitudes – Whether all available magnitude types should be included.

  • include_uncertainties – Whether value columns with uncertainties should be included.

  • include_ids – Whether event, origin, and magnitude IDs should be included.

  • include_quality – Whether columns with quality information should be included.

Returns:

catalog – Catalog object

Examples

>>> from seismostats import Catalog
>>> catalog = Catalog.from_quakeml("path/to/quakeml.xml")
>>> catalog

   longitude   latitude  depth                time  magnitude
0      42.35    3.34444   5.50 1900-01-01 05:05:13        1.0
1       1.35    5.13500  10.52 1982-04-07 07:07:15        2.5
2       2.35    2.13400  50.40 2020-11-30 12:30:59        3.9