NC: Perform na.locf About an xts Object

Description Usage Arguments Value Examples

View source: R/Functions.R

Description

1
Perform na.locf About an xts Object

Usage

1
NC(x, d = "f", ...)

Arguments

x

xts object

d

direction. "f"(default) forward. The other option is "b" backward.

...

dots passed

Value

xts object

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
## Not run: 

# NC(Perform na.locf About an xts Object) example

xts(c(NA_real_, 3, NA_real_,5, NA_real_), zoo::as.Date(0:4))
           [,1]
1970-01-01   NA
1970-01-02    3
1970-01-03   NA
1970-01-04    5
1970-01-05   NA

NC(xts(c(NA_real_, 3, NA_real_,5, NA_real_), zoo::as.Date(0:4)))
           V1nc.f
1970-01-01     NA
1970-01-02      3
1970-01-03      3
1970-01-04      5
1970-01-05      5

## End(Not run)

AndreMikulec/econModel documentation built on June 30, 2021, 9:48 a.m.