Skip to content

Commit

Permalink
Merge pull request #733 from deeptools/interintratadratio
Browse files Browse the repository at this point in the history
Interintratadratio
  • Loading branch information
joachimwolff authored Jul 10, 2021
2 parents 885fd7e + 0c5e910 commit 0d8855d
Show file tree
Hide file tree
Showing 12 changed files with 1,059 additions and 1 deletion.
7 changes: 7 additions & 0 deletions bin/hicInterIntraTAD
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-

from hicexplorer.hicInterIntraTAD import main

if __name__ == "__main__":
main()
4 changes: 4 additions & 0 deletions docs/content/list-of-tools.rst
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,8 @@ Tools for TADs processing
tools/hicMergeDomains
tools/hicDifferentialTAD
tools/hicMergeTADbins
tools/hicInterIntraTAD


Tools for Hi-C and TADs visualization
-------------------------------------
Expand Down Expand Up @@ -113,6 +115,8 @@ For single-cell Hi-C data analysis please use `scHiCExplorer <https://schicexplo
|:ref:`hicDifferentialTAD` | analysis | two Hi-C matrices | two diff_tad files: accepted H0 and | Identifies differential Topologically Associating Domains (TADs) between |
| | | one TAD domain file | rejected H0. Similar to BED6 | two Hi-C matrices |
+--------------------------------------+------------------+-----------------------------------+---------------------------------------------+-----------------------------------------------------------------------------------+
|:ref:`hicInterIntraTAD` | analysis | Hi-C matrix, TAD boundaries | data file and a plot | Computes and extracts TAD data. Creates a plot for the inter/intra contact ratio. |
+--------------------------------------+------------------+-----------------------------------+---------------------------------------------+-----------------------------------------------------------------------------------+
|:ref:`hicPlotMatrix` | visualization | hicMatrix object | a heatmap of Hi-C contacts | Plots a Hi-C matrix as a heatmap |
+--------------------------------------+------------------+-----------------------------------+---------------------------------------------+-----------------------------------------------------------------------------------+
|:ref:`hicPlotTADs` | visualization | hicMatrix object, a config file | Hi-C contacts on a given region, along with | Plots TADs as a track that can be combined with other tracks |
Expand Down
24 changes: 24 additions & 0 deletions docs/content/tools/hicInterIntraTAD.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
.. _hicInterIntraTAD:

hicInterIntraTAD
================

.. argparse::
:ref: hicexplorer.hicInterIntraTAD.parse_arguments
:prog: hicInterIntraTAD

This tool computes and extracts for given TADs the inter-left, inter-right and intra-TAD data: the absolute number of contacts, the density (non-zero contacts / all possible contacts) and the ratio of inter-left/intra, inter-right/intra and (inter-left + inter-right)/intra TAD contacts.
The data is saved in one file where it can be used for further, user-specific computations outside of HiCExplorer. Also a scatter plot of the ratio inter-left/intra vs. inter-right/intra is created.

.. code-block:: INI
# Created with HiCExplorer's hicInterIntraTAD version 3.7-dev
# Chromosome start end name score strand inter_left_sum inter_right_sum inter_left_density inter_right_density inter_left_number_of_contacts inter_right_number_of_contacts inter_left_number_of_contacts_nnz inter_right_number_of_contacts_nnz intra_sum intra_number_of_contacts intra_number_of_contacts_nnz intra_density inter_left_intra_ratio inter_right_intra_ratio inter_left_inter_right_intra_ratio
chr1 4400000 6200000 ID_0.01_1 -0.5630275 . 0 265.6981737879304 0 1.0 0 180 0 180 780.0186987409819 324 324 1.0 0.0 0.340630518494993 0.340630518494993
chr1 6200000 7300000 ID_0.01_2 -0.235798 . 288.00513572726237 327.503479611623 1.0 1.0 198 231 198 231 339.91508704783513 121 121 1.0 0.8472855330682405 0.9634861531331044 1.8107716862013452
chr1 7300000 9500000 ID_0.01_3 -0.44334 . 340.12385944568155 159.40880484157745 1.0 1.0 242 110 242 110 1078.1133262629996 484 484 1.0 0.31548061892958207 0.14785904316211984 0.46333966209170185
chr1 9500000 10100000 ID_0.01_4 -1.021538 . 186.65816676710497 124.2235190772146 1.0 1.0 132 84 132 84 118.58286349492002 36 36 1.0 1.5740737005823884 1.0475672067282826 2.6216409073106712
.. image:: ../../images/ratio.png
Binary file added docs/images/ratio.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 2 additions & 0 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,8 @@ tool description
:ref:`hicPlotSVL` Computing short vs long range contacts and plotting the results
:ref:`hicHyperoptDetectLoops` Search for optimal hicDectectLoops parameters
:ref:`hicHyperoptDetectLoopsHiCCUPS` Search for optimal Juicer HiCCUPS parameters
:ref:`hicInterIntraTAD` Extras and computes inter and intra TAD data

==================================== ==========================================================================================================================================================

Getting Help
Expand Down
Loading

0 comments on commit 0d8855d

Please sign in to comment.