Skip to contents

Get earthquake monitoring information from PHIVOLCS earthquake bulletin HTMLs

Usage

eq_get_tables(
  .url = "https://earthquake.phivolcs.dost.gov.ph/",
  .year = NULL,
  .month = NULL,
  latest = TRUE
)

eq_get_table(.url)

Arguments

.url

Base URL for PHIVOLCS earthquake bulletins.

.year

A vector for year (in YYYY format) for which earthquake bulletins are to be retrieved. The earliest year that can be specified is 2018. If set to NULL (default), all years starting from 2018 to present year are used.

.month

A vector for month for which earthquake bulletins are to be retrieved. This can be set as either an integer index (1 for January) or abbreviation (Jan for January) for full name. If set to NULL (default), all months are used.

latest

Logical. Should the latest table of earthquake information be retrieved? Only evaluated if .year = NULL and .month = NULL. If TRUE (default), table of earthquake information for current year and current month is retrieved. Otherwise, all months for all possible years are retrieved.

Value

A list of tibble/s of raw earthquake information from PHIVOLCS.

Examples

eq_get_tables()
#> [[1]]
#> # A tibble: 1,483 × 7
#>    date_time_retrieved `Date - Time(Philippine Time)` Latitude\n              …¹
#>    <dttm>              <chr>                          <chr>                     
#>  1 2024-08-19 21:08:08 20 August 2024 - 04:58 AM      8.02                      
#>  2 2024-08-19 21:08:08 20 August 2024 - 04:54 AM      8.38                      
#>  3 2024-08-19 21:08:08 20 August 2024 - 04:53 AM      8.22                      
#>  4 2024-08-19 21:08:08 20 August 2024 - 04:44 AM      8.05                      
#>  5 2024-08-19 21:08:08 20 August 2024 - 04:42 AM      9.67                      
#>  6 2024-08-19 21:08:08 20 August 2024 - 04:42 AM      8.02                      
#>  7 2024-08-19 21:08:08 20 August 2024 - 04:40 AM      7.92                      
#>  8 2024-08-19 21:08:08 20 August 2024 - 04:37 AM      7.94                      
#>  9 2024-08-19 21:08:08 20 August 2024 - 04:34 AM      12.79                     
#> 10 2024-08-19 21:08:08 20 August 2024 - 04:30 AM      8.02                      
#> # ℹ 1,473 more rows
#> # ℹ abbreviated name: ¹​`Latitude\n              (ºN)`
#> # ℹ 4 more variables: `Longitude\n              (ºE)` <chr>,
#> #   `Depth\n              (km)` <chr>, Mag <chr>, Location <chr>
#>