patch: Patch missing values in a vector.

Description Usage Arguments Value Note Author(s) Examples

View source: R/patch.R

Description

Patch NAs in a vector with existing values.

Usage

1
patch(x)

Arguments

inputvector

Value

A vector of the same class as the input vector.

Note

This function is similar to the fill function.

Author(s)

Joost van de Weijer

Examples

1
2
3
4
5
6
7
inputvector=c(1,NA,NA,NA,2,NA,NA,NA,3,NA,4,5)
patch(inputvector)

## The function is currently defined as
function (x)
{
  }

vdweijer/supply documentation built on June 28, 2021, 7:45 a.m.