twinfer.inference.covariance_decomposition_z_scores.clone_twin_stats_matrix
- twinfer.inference.covariance_decomposition_z_scores.clone_twin_stats_matrix(X, Y, clone, chunk_x=None, chunk_y=None, keys=None)[source]
Statistics of every pair (column of X, column of Y) for cells with clone labels.
- Parameters:
X (array, array, array) – X: cells x nx array, Y: cells x ny array (values used as given, e.g. CP10k), clone: one label per cell.
Y (array, array, array) – X: cells x nx array, Y: cells x ny array (values used as given, e.g. CP10k), clone: one label per cell.
clone (array, array, array) – X: cells x nx array, Y: cells x ny array (values used as given, e.g. CP10k), clone: one label per cell.
chunk_x (int, optional) – Process the pairs in blocks of that many regulator / target columns (needed when nx * ny is large: the cost in memory is about (number of within-clone cell pairs) x chunk columns); None = everything at once.
chunk_y (int, optional) – Process the pairs in blocks of that many regulator / target columns (needed when nx * ny is large: the cost in memory is about (number of within-clone cell pairs) x chunk columns); None = everything at once.
keys (list of str, optional) – Which statistics to return (default all).
- Returns:
(nx, ny) arrays: rho, S, C, U, rho_Delta, h_x, h_y, sigma_rho, sigma_C, sigma_D, z_rho, z_rho_s, z_rho_Delta.
- Return type:
dict