M2 Lab5 - areed37/Andrew_Reed_EPP_531 GitHub Wiki
3D DNA
#making new folder for this lab
mkdir 3D-DNA
cd 3D-DNA
#link to fasta and juicer output
#our juicer ran into an error so we had to use example files
ln -s /pickett_sphinx/projects/EPP531_AGA/jesseparker/hifiasm_data/Juicer/aligned .
ln -s /pickett_sphinx/projects/EPP531_AGA/jesseparker/hifiasm_data/Juicer/references .
spack load /acgsl7y
#run 3Dna
bash /pickett_shared/software/3d-dna-201008/run-asm-pipeline.sh \
assembly-CP_filtered.fasta.filtered \
merged_nodups.txt
#finalize 3Dna
bash /pickett_shared/software/3d-dna-201008/finalize/finalize-output-w-stats.sh \
-c 12 \ #no. of chromosomes
-s 15000 \ #tiny_thresholds
-l Your_Assembly \
Your_Assembly.final.cprops \
Your_Assembly.final.asm \
Your_Assembly.final.fasta \
final \
>& Your_Assembly.3d_dna_final.out
scp final.asm
scp final.hic
SyRI
mkdir Syri
cd Syri
#link the files to current directory
cp /pickett_sphinx/projects/EPP531_AGA/lyadav_EPPAGA/Syri/Dogwood_hap1-vs-hap2_Chr9.bam .
cp -s /pickett_sphinx/projects/EPP531_AGA/lyadav_EPPAGA/Syri/*.fa .
#align the two fasta sequences
spack load minimap2
minimap2 -ax asm5 -t 5 hap1_subset_9.fa hap1_subset_9.fa > hap1-vs-hap2.sam
singularity exec -B $PWD /sphinx_local/images/syri_1.6.3--py38hdbdd923_2.sif syri \
-c Dogwood_hap1-vs-hap2_Chr9.bam \
-r hap1_subset_9.fa \
-q hap2_subset_9.fa \
-F B --cigar --nc 3
#use output from syri for conda plotstar
#Install plotsr with conda
conda create -n plotsr
conda activate plotsr
conda install bioconda::plotsr
#Run Plotsr
plotsr --sr syri.out --genomes \
genomes.txt \
-o ChBrave_chr9-vs-K2_chr9.png \ #output file name
-H 8 \ #height
-W 10 \ #width
-d 300 #dpi
conda deactivate