vec2mat: Fills a triangular matrix from the inputed vector

Description Usage Arguments Value Examples

View source: R/vec2mat.R

Description

Fills a triangular matrix from the inputed vector

Usage

1

Arguments

x

a vector

diag

whether the vector contains the diagonal elements

upper

whether the vector contains the upper trinagular matrix elements

Value

a matrix

Examples

1
2
3
4
5
{
 vec2mat(1:10)
 vec2mat(1:10,diag=TRUE)
 vec2mat(1:10,upper=TRUE)
}

hierfstat documentation built on Nov. 17, 2021, 5:08 p.m.