Commit f9586e0f authored by nfontrod's avatar nfontrod
Browse files

src/commands.sh: add creation of meatagene and gc content figure for...

src/commands.sh: add creation of meatagene and gc content figure for readthrough, readthrough_ctcf and no_readthrough exon list
parent 397729a7
Pipeline #151 passed with stages
in 1 minute and 16 seconds
......@@ -775,3 +775,63 @@ python3 -m src.visu \
--norm "None"
mv results/figures/metagene_all_gene_100bin_0_nt-around-0-bin.pdf results/figures/metagene_5y_rnaseq_TSS-2kb_all_gene.pdf
#####################################################
# Metagene figure of last exons in readthrough genes near (<=2000 nt) or far (> 2000nt) from a CTCF file and last exons from non readthrough genes
#####################################################
# Bed file containing the last exons of expressed gene with readthrough
python3 -m src.bed_handler.get_last_exons -g results/bed_file/readthrough_expressed_gene.bed -o results/bed_file/readthrough_expressed_last_exon.bed
# Bed file containing the last exons of expressed gene without readthrough
python3 -m src.bed_handler.get_last_exons -g results/bed_file/no_readthrough_expressed_gene.bed -o results/bed_file/no_readthrough_expressed_last_exon.bed
# Bed file containing the last exon in expressed genes with readthrough near CTCF (<=2000nt)
python3 -m src.bed_handler.select_regulated_near_ctcf_exons -e results/bed_file/readthrough_expressed_last_exon.bed -t 2000 -l both -i True -N True -n readthrough_last_exon
# Bed file containing the last exon in expressed genes with readthrough near CTCF (>2000nt)
python3 -m src.bed_handler.select_regulated_near_ctcf_exons -e results/bed_file/readthrough_expressed_last_exon.bed -t 2000 -l both -i True -N False -n readthrough_last_exon
cp results/bed_file/no_readthrough_expressed_gene.bed results/bed_file/no_readthrough_expressed_last_gene-dup.bed
list_names=(readthrough_ctcf readthrough no_readthrough)
bed_names=(readthrough_last_exon_near_CTCF_2000_both_ddx_with0_exon.bed readthrough_last_exon_far_CTCF_2000_both_ddx_with0_exon.bed no_readthrough_expressed_last_exon.bed)
for i in ${!list_names[*]}; do
cname=${list_names[i]}
bed=${bed_names[i]}
gbed=${bed/exon\.bed/gene-dup.bed}
nbed=${gbed/\.bed/}
python3 -m src.visu \
--design data/design_exp_all_replicates.txt \
--bw_folder data/bigwig/ \
--region_bed results/bed_file/${gbed} \
--region_name ${cname} \
--output results/figures/ \
--border_name TSS TTS \
--environment 10000 25 \
--show_replicate n \
--figure_type metagene \
--nb_bin 100 \
--norm '0'
rm results/figures/metagene_${cname}_100bin_10000_nt-around-25-bin_b0_norm.pdf
python3 -m src.visu \
--design data/design_exp_all_replicates.txt \
--bw_folder data/bigwig/ \
--region_bed results/bed_file/${bed} \
--region_name ${cname} \
--output results/figures/ \
--border_name " " " " \
--environment 10000 25 \
--show_replicate n \
--figure_type metagene \
--nb_bin 30 \
-y 0.15 0.4 \
--norm "results/figures/coef_table/tmp_cov_table_design_exp_all_replicates_${nbed}_100bin_10000_nt-around-25-bin_bin0_norm.txt"
mv results/figures/metagene_${cname}_30bin_10000_nt-around-25-bin_file_norm.pdf results/figures/all_replicates_metaexon_${cname}_30bin_10000_nt-around-25-bin_file_norm.pdf
done
python3 -m src.gc_content -B results/bed_file/readthrough_last_exon_near_CTCF_2000_both_ddx_with0_exon.bed results/bed_file/readthrough_last_exon_far_CTCF_2000_both_ddx_with0_exon.bed results/bed_file/no_readthrough_expressed_last_exon.bed -b readthrough_ctcf readthrough no_readthrough -g data/Homo_sapiens.GRCh37.dna.primary_assembly.fa -f "exons" -e 2000
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment