ones: Generates a matrix of ones

Description Usage Arguments Details Value Author(s) See Also Examples

Description

ones generates a matrix of ones.

Usage

1
ones(n, p = n)

Arguments

n

number of rows

p

number of columns

Details

if only n is specified, the resulting matrix will be square.

Value

a matrix filled with ones.

Author(s)

Jan Graffelman (jan.graffelman@upc.edu)

See Also

matrix

Examples

1
2
Id <- ones(3)
print(Id)

calibrate documentation built on May 29, 2017, 2:01 p.m.

Search within the calibrate package
Search all R packages, documentation and source code