read_ianigla: Reads data from Sistema de Monitoreo Meteorológico de Alta...

View source: R/ff_read_ianigla.R

read_ianiglaR Documentation

Reads data from Sistema de Monitoreo Meteorológico de Alta Montaña (IANIGLA - Argentina)

Description

Reads csv files downloaded from the Sistema de Monitoreo Meteorológico de Alta Montaña web page as a data frame.

Usage

read_ianigla(path, by = "1 hour", out_name = NULL)

Arguments

path

path to the csv file.

by

string with the time step of the series (e.g.: 'month', 'day', '6 hour', '3 hour', '1 hour', '15 min' ). The default value is '1 hour'. If you set it as 'none', the function will ignore automatic gap filling.

out_name

optional. String vector with user defined variable(s) column(s) name(s).

Value

A data frame with the data inside the csv file. Gaps between dates are filled with NA_real_ and duplicated rows are eliminated automatically.

Examples


# set path to file
path_file <- system.file('extdata', 'ianigla_cuevas.csv',
             package = 'hydrotoolbox')

# read with default names
head( read_ianigla(path = path_file) )

# set column names
head(
read_ianigla(path = path_file,
             out_name = c('tair(°C)', 'rh(%)', 'patm(mbar)',
                           'p(mm)', 'wspd(km/hr)', 'wdir(°)',
                           'kin(kW/m2)', 'hsnow(cm)', 'tsoil(°C)' ) )
)


hydrotoolbox documentation built on April 14, 2023, 12:34 a.m.