split_data: Split up data matrix by subgroups

View source: R/update_dist.R

split_dataR Documentation

Split up data matrix by subgroups

Description

Split up data matrix by subgroups

Usage

split_data(data, by = rep(1, nrow(data)), names = unique(by), warn = 10)

Arguments

data

matrix, contains (binary 0/1) data

by

integer vector

names

character, names of subgroups

warn

integer, a warning is given if length(unique(by)) > warn

Details

useful to pass data to update_dist if groups(dist) > 1

Value

a list of data matrices


maxwestphal/SIMPle documentation built on April 11, 2024, 4:07 p.m.