Learn R Programming

solaR (version 0.14)

fBTd: Daily time base

Description

Construction of a daily time base for solar irradiation calculation

Usage

fBTd(Modo = "DiasProm", 
    Ano = as.POSIXlt(Sys.Date())$year + 1900, 
    FechaInicio = paste("01-01-", Ano, sep = ""), 
    FechaFinal = paste("31-12-", Ano, sep = ""), 
    FechaBaseDatos, FormatoFecha)

Arguments

Modo
character, controls the type of time base to be created. With Modo='BaseDatos' the time series is created according to a solar irradiation database, translating the information about measuring dates contained in FechaBaseDatos. W
Ano
which year is to be used for the time base when Modo='DiasProm'. Its default value is the current year.
FechaInicio
first day of the time base for Modo='Serie'. Its default value is the first of January of the current year.
FechaFinal
last day of the time base for Modo='Serie'. Its default value is the last day of December of the current year.
FechaBaseDatos
numeric vector containing the information about measurement events of the daily solar irradiation database when Modo='BaseDatos'
FormatoFecha
character, defines the format of the information in FechaBaseDatos. It shall follow the rules of the strptime function. For example, '%d-%m-%Y'

Value

  • This function returns a data.frame with components adequately obtained from the functions as.POSIXlt and strptime.
  • IDdnumeric, a value which identifies each day of the time series. It is useful for daily summaries when several years are included in the database
  • Anonumeric, year
  • DiaAnonumeric, day of the year
  • Mesnumeric, month
  • DiaMesnumeric, day of the month

encoding

UTF-8

Details

This function is commonly used inside fSolD.

References

Perpiñán, O, Energía Solar Fotovoltaica, 2010. (http://procomun.wordpress.com/documentos/libroesf/)

See Also

fSolD, LeeMAPA

Examples

Run this code
#Average days
(fBTd(Modo='DiasProm'))

Run the code above in your browser using DataLab