Estimate Joint Rank via Cross-View RV Analysis

estimate_rank_by_permutation_rv(
  mat_list,
  n_permutations = 20,
  var_explained_threshold = 0.9,
  handle_missing = TRUE,
  return_max = FALSE
)

Arguments

mat_list

A list of numeric matrices [subjects x features].

n_permutations

Number of permutations (0 = Elbow method).

var_explained_threshold

Variance threshold to determine individual k_max.

handle_missing

Boolean; if TRUE, replaces NA/Constant columns with row means.

return_max

Boolean; if TRUE, returns only the k_max and skips curves.

Value

A list containing optimal_k, results tibble, and a diagnostic plot.