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.0.0.tar.gz (17.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.0.0-py3-none-any.whl (21.7 kB view details)

Uploaded Python 3

File details

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

File metadata

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

File hashes

Hashes for atacofthesnake-0.0.0.tar.gz
Algorithm Hash digest
SHA256 af65078b60449f418ad6c67e73b5c3952a7a31f52cee5e8dc5d1e406ecbacf0a
MD5 4697c9fed3b621c32e2f2d2c8b5c7883
BLAKE2b-256 d16251b01bf0b93acd3e8c2aac53ca3a6853b725e2dc4a15fbd912f6ee23a585

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for atacofthesnake-0.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 2cbd97527f2e17eda7b5d0fed6177a894c2de4ec2c296fbab393d0b4334033f8
MD5 84f8d9b05a2619f81c539eac54b309fc
BLAKE2b-256 aeb9715cae99f6f38023363f8cf9b17da71e336bab8ec7c39c3077706cd1e25a

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