Learn R Programming

units (version 0.8-5)

seq.units: seq method for units objects

Description

seq method for units objects

Usage

# S3 method for units
seq(from, to, by = ((to - from)/(length.out - 1)),
  length.out = NULL, along.with = NULL, ...)

Arguments

from

see seq

to

see seq

by

see seq

length.out

see seq

along.with

see seq

...

see seq

Details

arguments with units are converted to have units of the first argument (which is either from or to)

Examples

Run this code
seq(to = set_units(10, m), by = set_units(1, m), length.out = 5)
seq(set_units(10, m), by = set_units(1, m), length.out = 5)
seq(set_units(10, m), set_units(19, m))
seq(set_units(10, m), set_units(.1, km), set_units(10000, mm))

Run the code above in your browser using DataLab