lhqxinghun / scKTLD

A python package for identifying TAD-like domains on single-cell Hi-C data
MIT License
2 stars 1 forks source link

scKTLD

1. Introduction

scKTLD is a method designed for the identification of TAD-like domains on single-cell Hi-C data. It treats the Hi-C contact matrix as a graph, embeds its structures into a low-dimensional space by combining sparse matrix factorization and spectral propagation, and identifies the TAD-like domains in the embedding space via a kernel model optimized by PELT image

2. Installation & Example

2.1 OS

2.2 Required Python Packages Make sure that all the packages listed in the requirements.txt are installed.

2.3 Install from Github

(1) Download the folder scKTLD by git clone

$ git clone https://github.com/lhqxinghun/scKTLD/

(2) Install the package scKTLD with the following command:

$ conda create -n scKTLD python=3.6
$ conda activate scKTLD
$ pip install Cython
$ cd scKTLD
$ pip install . #or you can try python setup.py install 

2.4 Or install from the standard package source PyPI

$ conda create -n scKTLD python=3.6
$ conda activate scKTLD
$ pip install Cython scKTLD

2.5 Run example

$ cd scKTLD
$ python example.py
# If it works properly, You can find the result files in the output directory, including the .txt file that contains the
identified TAD-like domain boundaries and the .tiff file for visualization. The .tiff file in the example is shown as follows:

image

More detailed examples can be find in the jupyter notebook example.ipynb

3. Usage

(1) The key function in this package is callTLD, it has the following input and output:

Input:

(2) For sparse format of a contact matrix, scKTLD provides function edge2adj to convert it to an adjacency matrix (dense format), which can be directly input to the fucntion callTLD

Input:

4. Contact

hongqianglv@mail.xjtu.edu.cn OR liuerhu@stu.xjtu.edu.cn