NOTE: THIS RELEASE BREAKS BACKWARDS COMPATIBILITY!
This release addresses two major issues:
- Integration with bioframe viewframes defined as of bioframe v0.3.
- Synchronization of the CLI and Python API
Additionally, the documentation has been greatly improved and now includes detailed tutorials that show how to use the cooltools
API in conjunction with other Open2C libraries. These tutorials are automatically re-built from notebooks copied from https://github.com/open2c/open2c_examples repository.
-
More clear separation of top-level user-facing functions and low-level API.
- Most standard analyses can be performed using just the user-facing functions which are imported into the top-level namespace. Some of them are new or heavily modified from earlier versions.
-
cooltools.expected_cis
andcooltools.expected_trans
for average by-diagonal contact frequency in intra-chromosomal data and in inter-chromosomal data, respectively -
cooltools.eigs_cis
andcooltools.eigs_trans
for eigenvectors (compartment profiles) of cis and trans data, repectively -
cooltools.digitize
andcooltools.saddle
can be used together for creation of 2D summary tables of Hi-C interactions in relation to a digitized genomic track, such as eigenvectors -
cooltools.insulation
for insulation score and annotation of insulating boundaries -
cooltools.directionality
for directionality index -
cooltools.pileup
for average signal at 1D or 2D genomic features, including APA -
cooltools.coverage
for calculation of per-bin sequencing depth -
cooltools.sample
for random downsampling of cooler files -
For non-standard analyses that require custom algorithms, a lower level API is available under
cooltools.api
-
- Most standard analyses can be performed using just the user-facing functions which are imported into the top-level namespace. Some of them are new or heavily modified from earlier versions.
-
Most functions now take an optional
view_df
argument. A pandas dataframe defining a genomic view (https://bioframe.readthedocs.io/en/latest/guide-technical-notes.html) can be provided to limit the analyses to regions included in the view. If not provided, the analysis is performed on whole chromosomes according to what’s stored in the cooler. -
All functions apart from
coverage
now take aclr_weight_name
argument to specify how the desired balancing weight column is named. Providing aNone
value allows one to use unbalanced data (except theeigs_cis
,eigs_trans
methods, since eigendecomposition is only defined for balanced Hi-C data). -
The output of
expected-cis
function has changed: it now containsregion1
andregion2
columns (with identical values in case of within-region expected). Additionally, it now allows smoothing of the result to avoid noisy values at long distances (enabled by default and result saved in additional columns of the dataframe) -
The new
cooltools.insulation
method includes a thresholding step to detect strong boundaries, using either the Li or the Otsu method (fromskimage.thresholding
), or a fixed float value. The result of thresholding for each window size is stored as a boolean in a new columnis_boundary_{window}
. -
New subpackage
sandbox
for experimental codes that are either candidates for merging into cooltools or candidates for removal. No documentation and tests are expected, proceed at your own risk. -
New subpackage
lib
for auxiliary modules
- CLI tools are renamed with prefixes dropped (e.g.
diamond-insulation
is nowinsulation
), to align with names of user-facing API functions. - The CLI tool for expected has been split in two for intra- and inter-chromosomal data (
expected-cis
andexpected-trans
, repectively). - Similarly, the compartment profile calculation is now separate for cis and trans (
eigs-cis
andeigs-trans
). - New CLI tool
cooltools pileup
for creation of average features based on Hi-C data. It takes a .bed- or .bedpe-style file to create average on-diagonal or off-diagonal pileups, respectively.
Support for Python 3.6 dropped
Date: 2021-04-06
Maintenance
- Make saddle strength work with NaNs
- Add output option to diamond-insulation
- Upgrade bioframe dependency
- Parallelize random sampling
- Various compatibility fixes to expected, saddle and snipping and elsewhere to work with standard formats for "expected" and "regions": open2c#217
New features
- New dataset download API
- New functionality for smoothing P(s) and derivatives (API is not yet stable):
logbin_expected
,interpolate_expected
Date: 2020-05-05
Updates and bug fixes
- Error checking for vmin/vmax in compute-saddle
- Various updates and fixes to expected and dot-caller code
Project health
- Added docs on RTD, tutorial notebooks, code formatting, linting, and contribution guidelines.
Date: 2019-11-04
-
Several library utilities added:
plotting.gridspec_inches
,adaptive_coarsegrain
, singleton interpolation, and colormaps. -
New tools:
cooltools sample
for random downsampling,cooltools coverage
for marginalization.
Improvements to saddle functions:
compute-saddle
now saves saddledata without transformation, and thescale
argument (with optionslog
orlinear
) now only determines how the saddle is plotted. Consequently,saddleplot
function now expects untransformedsaddledata
, and plots it directly or with log-scaling of the colormap. (open2c#105)- Added
saddle.mask_bad_bins
method to filter bins in a track based on Hi-C bin-level filtering - improves saddle and histograms when using ChIP-seq and similar tracks. It is automatically applied in the CLI interface. Shouldn't affect the results when using eigenvectors calculated from the same data. make_saddle
Python function andcompute-saddle
CLI now allow setting min and max distance to use for calculating saddles.
Date: 2019-05-02
- New tagged release for DCIC. Many updates, including more memory-efficient insulation score calling. Next release should include docs.
Date: 2018-05-07
- First official release