get_wecove: Create a weighted co-occurrence vector (wecove)

View source: R/get_wecove.R

get_wecoveR Documentation

Create a weighted co-occurrence vector (wecove)

Description

Converts a weighted co-occurrence matrix (wecoma) to a weighted co-occurrence vector (wecove)

Usage

get_wecove(x, ordered = TRUE, normalization = "none")

Arguments

x

A matrix - an output of the get_wecoma() function

ordered

The type of pairs considered. Either "ordered" (TRUE) or "unordered" (FALSE). The default is TRUE.

normalization

Should the output vector be normalized? Either "none" or "pdf". The "pdf" option normalizes a vector to sum to one. The default is "none".

Value

A weighted co-occurrence vector

Examples

library(comat)
data(raster_x, package = "comat")
data(raster_w, package = "comat")

wom = get_wecoma(raster_x, raster_w)
wom

wov = get_wecove(wom)
wov

comat documentation built on April 5, 2023, 5:12 p.m.