uchrom.strc.comp

A/B compartment detection from chromatin-tracing data.

class uchrom.strc.comp.CompartmentCallerParams(n_clusters: 'int' = 2, min_bins: 'int' = 2, k_sigma: 'float' = 4.0, frac: 'float' = 0.1, random_state: 'int' = 0, a_cluster: 'Optional[int]' = None)[source]

Bases: object

a_cluster: int | None = None
frac: float = 0.1
k_sigma: float = 4.0
min_bins: int = 2
n_clusters: int = 2
random_state: int = 0
uchrom.strc.comp.call_compartments_axes_pc(cd, chrom: str, params: CompartmentCallerParams | None = None, device: str = 'auto', store: bool = True, result_key: str = 'compartments', verbose: bool = False) DataFrame[source]

Call A/B compartments on a single chromosome.

Returns a DataFrame indexed by bin. Stores it in cd.results[result_key] when store=True.

class uchrom.strc.comp.axes_pc.CompartmentCallerParams(n_clusters: 'int' = 2, min_bins: 'int' = 2, k_sigma: 'float' = 4.0, frac: 'float' = 0.1, random_state: 'int' = 0, a_cluster: 'Optional[int]' = None)[source]

Bases: object

a_cluster: int | None = None
frac: float = 0.1
k_sigma: float = 4.0
min_bins: int = 2
n_clusters: int = 2
random_state: int = 0
uchrom.strc.comp.axes_pc.call_compartments_axes_pc(cd, chrom: str, params: CompartmentCallerParams | None = None, device: str = 'auto', store: bool = True, result_key: str = 'compartments', verbose: bool = False) DataFrame[source]

Call A/B compartments on a single chromosome.

Returns a DataFrame indexed by bin. Stores it in cd.results[result_key] when store=True.