Skip to contents

Efficiently computes trajectory-based GFC for each column of a matrix, reusing graph structure across all computations. Supports parallel execution via OpenMP.

Usage

compute.gfc.flow.matrix(
  adj.list,
  weight.list,
  Y,
  density = NULL,
  modulation = c("CLOSEST", "NONE", "DENSITY", "EDGELEN", "DENSITY_EDGELEN"),
  n.cores = 1L,
  verbose = FALSE,
  edge.length.quantile.thld = 0.9,
  long.edge.fallback = c("allow_and_flag", "allow", "forbid"),
  apply.relvalue.filter = TRUE,
  min.rel.value.max = 1.1,
  max.rel.value.min = 0.9,
  apply.maxima.clustering = TRUE,
  apply.minima.clustering = TRUE,
  max.overlap.threshold = 0.15,
  min.overlap.threshold = 0.15,
  apply.geometric.filter = TRUE,
  p.mean.nbrs.dist.threshold = 0.9,
  p.mean.hopk.dist.threshold = 0.9,
  p.deg.threshold = 0.9,
  min.basin.size = 10L,
  hop.k = 2L,
  store.trajectories = TRUE,
  max.trajectory.length = 10000L,
  symmetric.seeding = TRUE
)

Arguments

adj.list

List of integer vectors (adjacency list, 1-based).

weight.list

List of numeric vectors (edge weights).

Y

Numeric matrix of function values (n.vertices x n.functions).

density

Optional numeric vector of density values.

modulation

Character string specifying gradient modulation.

n.cores

Integer number of OpenMP threads. Default is 1 (sequential).

verbose

Logical. Print progress messages.

edge.length.quantile.thld

Numeric quantile threshold used by optional edge-length filtering.

long.edge.fallback

Character CLOSEST fallback policy; see compute.gfc.trajectory.

apply.relvalue.filter

Logical; apply relative-value-based basin filtering.

min.rel.value.max

Numeric lower bound for local-maximum relative value during filtering.

max.rel.value.min

Numeric upper bound for local-minimum relative value during filtering.

apply.maxima.clustering

Logical; cluster nearby local maxima before downstream filtering.

apply.minima.clustering

Logical; cluster nearby local minima before downstream filtering.

max.overlap.threshold

Numeric overlap threshold used when clustering maxima.

min.overlap.threshold

Numeric overlap threshold used when clustering minima.

apply.geometric.filter

Logical; apply geometric filters to remove unstable basins.

p.mean.nbrs.dist.threshold

Quantile threshold for mean neighbor distance filter.

p.mean.hopk.dist.threshold

Quantile threshold for hop-k distance filter.

p.deg.threshold

Quantile threshold for degree-based geometric filtering.

min.basin.size

Minimum basin size retained after filtering.

hop.k

Hop radius used for hop-based geometric diagnostics.

store.trajectories

Logical; retain trajectory objects in each result.

max.trajectory.length

Integer maximum allowed trajectory length.

symmetric.seeding

Logical; if TRUE, additionally seed trajectories from local maxima using descending flow.

Value

List of gfc.flow results, one per column of Y.