Learn R Programming

salad (version 1.2)

rep: Replicate elements of a dual vector

Description

A method extending `rep` to dual objects

Usage

# S3 method for dual
rep(x, ...)

Value

A dual object.

Arguments

x

a dual vector

...

extra parameters (typically, 'times', 'length.out' or 'each')

Examples

Run this code
x <- rep( dual(1:2), each = 4 )
x
d(x)

Run the code above in your browser using DataLab