triangle_to_sym: Convert a sparse triangle matrix to a sparse symmetric...

Description Usage Arguments Value Examples

View source: R/conversion.R

Description

Convert a sparse triangle matrix to a sparse symmetric matrix.

Usage

1

Arguments

trimat

A triangular sparse matrix (either upper or lower triangle can be filled).

Value

A symmetric sparse matrix.

Examples

1
2
triangleMatrix <- Matrix::Matrix(c(1,0,0,2,5,0,1,0,0), 3, sparse = T)
symmMatrix <- triangle_to_sym(triangleMatrix)

AnnikaGable/chromium documentation built on July 12, 2018, 4 p.m.