getql: Summarize data for SBM according to the different location...

Description Usage Arguments Value

View source: R/RcppExports.R

Description

This function determines how many observations are in each location group and species group for two cases: - when dat(i,j)=1: these results are stored in matrix nql1 - when dat(i,j)=0: these results are stored in matrix nql0

Usage

1
getql(z, w, dat, ngrloc, ngrspp)

Arguments

z

integer vector with cluster assignments of locations

w

integer vector with cluster assignments of species

dat

this matrix has L rows (e.g., locations) and S columns (e.g., species) and contains the presence-absence data

ngrloc

number of location groups (KL)

ngrspp

number of species groups (KS)

Value

this function returns a list with two KL x KS matrices: nql1 and nql0


drvalle1/EcoCluster documentation built on Jan. 25, 2022, 12:46 a.m.