deepof.post_hoc.compute_transition_matrix_per_condition

deepof.post_hoc.compute_transition_matrix_per_condition(embedding: deepof_table_dict, soft_counts: deepof_table_dict, breaks: deepof_table_dict, exp_conditions: dict, silence_diagonal: bool = False, bin_size: int | None = None, bin_index: int | None = None, aggregate: str = True, normalize: str = True)

Compute the transition matrices specific to each condition.

Parameters:
  • embedding (TableDict) – A dictionary of embeddings, where the keys are the names of the experimental conditions, and the values are the embeddings for each condition.

  • soft_counts (TableDict) – A dictionary of soft counts, where the keys are the names of the experimental conditions, and the values are the soft counts for each condition.

  • breaks (TableDict) – A dictionary of breaks, where the keys are the names of the experimental conditions, and the values are the breaks for each condition.

  • exp_conditions (dict) – A dictionary of experimental conditions, where the keys are the names of the experiments, and the values are the names of their corresponding

  • silence_diagonal (bool) – If True, diagonal elements on the transition matrix are set to zero.

  • bin_size (int) – The size of the time bins to use. If None, the embeddings are not binned.

  • bin_index (int) – The index of the bin to use. If None, the embeddings are not binned.

  • aggregate (str) – Whether to aggregate the embeddings across time.

  • normalize (str) – Whether to normalize the population of each cluster across conditions.

Returns:

A dictionary of transition matrices, where the keys are the names of the experimental conditions, and the values are the transition matrices for each condition.