Skip to contents

This function downloads the weather forecast table provided by Senamhi according to the specified year.

Usage

senamhi_alerts_by_year(data = NULL, year = NULL)

Arguments

data

A tibble object containing the weather alert data.

year

A numeric value indicating the year of publication of the weather warning.

Value

A tibble object containing the weather alert data.

Examples

# \donttest{
library(geoidep)
data <- senamhi_alerts_by_year(year = 2024)
#> Reading data from the website...
#> Data successfully uploaded.
head(data)
#> # A tibble: 6 × 7
#>   aviso                                nro   emision inicio fin   duracion nivel
#>   <chr>                                <chr> <chr>   <chr>  <chr> <chr>    <chr>
#> 1 PRECIPITACIONES EN LA SIERRA         399   2024-1… 2025-… 2025… 71 Hrs.  NARA…
#> 2 LLUVIA EN LA SELVA                   398   2024-1… 2024-… 2025… 57 Hrs.  NARA…
#> 3 PRECIPITACIONES EN LA SIERRA         397   2024-1… 2024-… 2024… 71 Hrs.  NARA…
#> 4 INCREMENTO DE LA TEMPERATURA DIURNA… 396   2024-1… 2024-… 2024… 47 Hrs.  NARA…
#> 5 INCREMENTO DE LA TEMPERATURA DIURNA… 395   2024-1… 2024-… 2024… 37 Hrs.  NARA…
#> 6 PRECIPITACIONES EN LA SIERRA NORTE … 394   2024-1… 2024-… 2024… 57 Hrs.  NARA…
# }