as_assignment_matrix: Convert assignment result to a binary matrix

View source: R/utils.R

as_assignment_matrixR Documentation

Convert assignment result to a binary matrix

Description

Turns a tidy assignment result back into a 0/1 assignment matrix.

Usage

as_assignment_matrix(x, n_sources = NULL, n_targets = NULL)

Arguments

x

An assignment result object of class lap_solve_result

n_sources

Number of source nodes, optional

n_targets

Number of target nodes, optional

Value

Integer matrix with 0 and 1 entries


couplr documentation built on Jan. 20, 2026, 5:07 p.m.