came.utils.analyze.weight_linked_vars_by_expr

came.utils.analyze.weight_linked_vars_by_expr(dpair: DataPair, labels_or_probs: tuple | ndarray | DataFrame)

Compute the weights between homologies by their average expressions across (cell) groups.

Parameters:
  • dpair – the DataPair object

  • labels_or_probs – group (cell-type) labels or soft assignments (probabilities)

Returns:

  • df_var_links_expr (pd.DataFrame) – the weights between each pair of homologous genes

  • avg (pd.DataFrame) – concatenated average expressions