approximate_nocb: Next Observation Carried Back

Description Usage Arguments See Also Examples

Description

Next observation carry back in the values of the indicator.

Usage

1
approximate_nocb(dat, maxgap = 2)

Arguments

dat

Eurostat data frame

maxgap

The maximum number of missing observations that should be filled up with observation carry back.

See Also

Other approximate functions: approximate_interpolate(), approximate_locf()

Examples

1
2
3
4
5
6
7
8
9
{
example_df <- data.frame (
  geo = c(rep("AT", 4), rep("DE", 4)),
  time = rep(as.Date(c("2008-01-01", "2009-01-01",
  "2010-01-01", "2011-01-01")), 2),
  values = c( 1:4, NA_real_, NA_real_, 5,6)
 )
approximate_nocb( example_df )
}

antaldaniel/musicobservatory documentation built on Nov. 26, 2020, 6:27 p.m.