readSIAR: Meteorological data from the SIAR network.

A8_readSIARR Documentation

Meteorological data from the SIAR network.

Description

Download, interpolate and transform meteorological data fromm the SIAR network.

Usage

readSIAR(Lon = 0, Lat = 0,
         inicio = paste(year(Sys.Date())-1, '01-01', sep = '-'),
         final = paste(year(Sys.Date())-1, '12-31', sep = '-'),
         tipo = 'Mensuales', n_est = 3)

Arguments

Lon

numeric, longitude (degrees) of the location.

Lat

numeric, latitude (degrees) of the location.

inicio

character or Date, first day of the records.

final

character or Date, last day of the records.

tipo

character, tipe of the records. To choose between Mensuales, Semanales, Diarios, Horarios.

n_est

integer, select that number of stations closest to the given point and then perform an IDW (Inverse Distance Weighting) interpolation with these data.

Value

A Meteo object

Author(s)

Francisco Delgado López, Oscar Perpiñán Lamigueiro.

See Also

readG0dm, readBDd

Examples

library("data.table")

library("httr2")
library("jsonlite")

SIAR = readSIAR(Lon = -3.603, Lat = 40.033,
## Aranjuez, Comunity of Madrid, Spain
                inicio = '2023-01-01',
                final = '2023-05-01',
                tipo = 'Mensuales', n_est = 3)
SIAR


solaR2 documentation built on April 3, 2025, 6:11 p.m.