adjust_mat: Adjust Matrix

Description Usage Arguments Value

View source: R/adjust_mat_function.R

Description

adjust the dimensions of a source object to the dimensions of a target object

Usage

1
2
3
4
5
6
7
8
adjust_mat(
  source,
  target,
  remove = TRUE,
  add = TRUE,
  value = NA,
  returnlabels = FALSE
)

Arguments

source

A matrix which should be adjusted (one-mode & directed).

target

A matrix (one-mode & directed) to which the source object is compared with regard to its labels.

remove

Should rows and columns that are not present in the target object be removed?

add

Should rows and columns that are present in the target object but not in the source object be added to the source object?

value

The value to be inserted if a new row or column is added. By default, new cells are filled with NA values, but other sensible values may include -Inf or 0.

returnlabels

Return a list of added and removed row and column labels rather than the actual matrix, vector, or network object?

Value

Matrix


ITNr documentation built on March 13, 2020, 1:48 a.m.

Related to adjust_mat in ITNr...