Learn R Programming

climtrends (version 1.0.6)

FillDailyGapsWithSomeValue: fill missing days with some value

Description

FillDailyGapsWithSomeValue fills (literally) missing days with date+some value.

Usage

FillDailyGapsWithSomeValue(dataYearSeries,FromDate,ToDate, missingValue=-9999)

Arguments

dataYearSeries
dataframe with climate data
FromDate
starting date
ToDate
ending date
missingValue
value representing missing data

Value

complete time series.

Examples

Run this code
# xgdcnCA008201000.dat is from ECA COLLEGEVILLE temperature
setwd(system.file('extdata/', package='climtrends'))
dailyCollegeville <- ReadGHCNymd('xgdcnCA008201000.dat')
daylyCollegeville2<-FillDailyGapsWithSomeValue(dailyCollegeville,
'1916-06-01','2010-11-30', missingValue=NA)
str(dailyCollegeville)
str(daylyCollegeville2)

Run the code above in your browser using DataLab