matrix2df: Coverting the upper triangle of a symmetric numeric matrix...

View source: R/struc__matrix2df.R

matrix2dfR Documentation

Coverting the upper triangle of a symmetric numeric matrix into a data frame of three variables.

Description

For speed, this function does not check symetry of the input matrix. It is a user's responsibility to guarantee the input is a symmetric matrix. In addition, row names and column names must be the same to get a correct output.

Usage

matrix2df(m, diag = FALSE, named = FALSE, small = TRUE, val.class = "numeric")

Author(s)

Yu Wan (wanyuac@gmail.com)


wanyuac/handyR documentation built on June 10, 2024, 1:24 a.m.