Skip to main content

ATACofthesnake

Project description

ATACofthesnake

Downstream processing of ATAC data, including QC's and differential accessibility. Starting point are deduplicated bam files, could be obtained from snakePipes (https://github.com/maxplanck-ie/snakepipes).

Important

All samples in a 'run' have to belong to the same group. That means that out of all peaks/sample, a union will be made.

Fasta headers un field 0 (space delimited) are not allowed to contain a pipe character '|'.

Installation

From github:

git clone git@github.com:maxplanck-ie/ATACofthesnake.git
pixi run ATAC -h

From pypi:

pip install ATACofthesnake

Quickstart

standard analysis:

ATAC --bamdir folder/with/bamfiles/ --outputdir outputfolder
--gtf genes.gtf --genomefasta genome.fa
--snakemakeprofile profile -b read_attracting_regions.bed

Note that this pipeline depends on snakemake. Additionally, the snakemake environments are managed using conda, which means you need to have conda installed and configured. Make sure this is set in your snakemake profile (if you use one), when not using a profile, snakemake will be ran with the --use-conda flag by default.

The default analysis will generate:

  • sieved bamfiles. (cfr. --fragsize/-f & --read_attracting_regions/-b). Note that read attracting regions are obliged. At minimum this should contain the mitochondrial genome. Note that the mitochondrial contig is assumed to be named 'MT'. You can change this using --mitostring.
  • peaks called per bamfile (under peaks/) and a union of all peaks (peakset/).
  • bigwigs normalized using scalefactors and RPKM.
  • a number of QC plots (figures/) and metrics (qc/)

Differential analysis

Differential analysis requires the additional yaml file specifying the comparison (comparison.yaml) and the samplesheet.

ATAC --bamdir folder/with/bamfiles/ --outputdir outputfolder
--gtf genes.gtf --genomefasta genome.fa --genomesize 1.87e9
--snakemakeprofile profile -b read_attracting_regions.bed
--comparison comparison.yaml --samplesheet samplesheet.tsv

The samplesheet has to be a tab-separated file with the first column containing the sample names (as the bam files are named), and the other columns containing the factors that will make up the design. For example:

sample genotype treatment
sample1 WT DMSO
sample2 WT DMSO
sample3 WT drug
sample4 WT drug
sample5 KO DMSO
sample6 KO DMSO
sample7 KO drug
sample8 KO drug

will result in the following design:

~ genoype + treatment

or if --interaction is set:

~ genotype * treatment

Note the comparisons made need to be specified in the comparison.yaml file, a samplesheet alone is not enough. An example together with the above samplesheet would be:

comparison1:
  group1:
    genotype: 'WT'
  group2:
    genotype: 'KO'
wtdmso_vs_wtdrug:
  wtdmso:
    genotype: 'WT'
    treatment: 'DMSO'
  wtdrug:
    genotype: 'WT'
    treatment: 'drug'

In this case, 2 analyses would be performed (under folders 'comparison1' & 'wtdmso_vs_wtdrug'). In both cases all of the factor columns in the samplesheet will be used in the design.

A motif file in meme format can be supplied as well. If this is the case, the motifs will first be clustered, and motif enrichments will be calculated for all differential regions (using ame). Note that the 'reciprocal' differential peaks will be used as background. E.g. group2 differential peaks are background for group1 enrichments and vice versa. Note that this approach could be biased if there is a strong disbalance between those groups.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

atacofthesnake-0.3.0.tar.gz (59.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

atacofthesnake-0.3.0-py3-none-any.whl (21.9 kB view details)

Uploaded Python 3

File details

Details for the file atacofthesnake-0.3.0.tar.gz.

File metadata

  • Download URL: atacofthesnake-0.3.0.tar.gz
  • Upload date:
  • Size: 59.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.12

File hashes

Hashes for atacofthesnake-0.3.0.tar.gz
Algorithm Hash digest
SHA256 e6db6ea229eb53219960a8b711ec0d6cbea28a3557d258fc086dc31455b9ba60
MD5 f29a586a6b6e97b66184b08822f4fc1f
BLAKE2b-256 aef446bce42656008c2cd29a1619fe2576b48068f4c058086f381e1156ce1355

See more details on using hashes here.

File details

Details for the file atacofthesnake-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: atacofthesnake-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 21.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.12

File hashes

Hashes for atacofthesnake-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b6236884f2e1da46b2ee757f0e9db5c1e927b872242c96161b59d04474dd23dd
MD5 1f21904784ec69901835d013a00cf5e6
BLAKE2b-256 4eb27cb2b955f037c6c2e4eb5dc5212c504f961c442f965c55a0881633c3b86d

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page