row_vec: Row Vectors

Description Usage Arguments Value Examples

View source: R/row_vec.R

Description

Constructs a row vector.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
row_vec(..., use.names = TRUE)

## Default S3 method:
row_vec(..., use.names = TRUE)

## S3 method for class 'matrix'
row_vec(..., use.names = TRUE)

## S3 method for class 'data.frame'
row_vec(..., use.names = TRUE)

Arguments

...

The elements of the row vector.

use.names

Logical indicating whether or not names should be preserved.

Value

A row vector of dimension 1 x length(x).

Examples

1
2
3
4
5
6
7
row_vec(1:5)
row_vec(1, 2, 3, 4, 5)
row_vec(t(row_vec(1:5)))
row_vec(col_vec(1:5))
row_vec(pi, exp(1), sin(0))
row_vec(rnorm(3))
row_vec("a" = 1, "b" = 2)  # names are preserved by default

bgreenwell/bmisc documentation built on Sept. 24, 2019, 11:09 a.m.