This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| install.packages("ggpubr") | |
| . | |
| . | |
| . | |
| . | |
| checking for suffix of object files... o | |
| checking whether the compiler supports GNU C++... yes | |
| checking whether g++ -std=gnu++14 accepts -g... yes | |
| checking for g++ -std=gnu++14 option to enable C++11 features... none needed | |
| checking how to run the C++ preprocessor... g++ -std=gnu++14 -E |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| venn_plot <- ggvenn::ggvenn(list_of_four_vectors) | |
| venn_plot$layers[[3]]$data$x <- c(-1, -0.8, 0.8, 1) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| get_maint_time () { | |
| maint_start=$(scontrol show -u root reservation \ | |
| | perl -pe 's/\n/#/g' \ | |
| | perl -pe 's/#ReservationName=/\n/g' \ | |
| | grep MAINT \ | |
| | perl -ne '/.+StartTime=(.+)\sEndTime/; print $1;') | |
| difftime=$(($(date +%s -d "$maint_start") - $(date +%s) - 1000)) | |
| req_len=$(date -d "@$difftime" "+$(($difftime/86400))-%H:%M:%S") | |
| echo $req_len | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # find and chmod files that aren't 444 in a couple directories | |
| for directory in BCLs FASTQs Counts | |
| do | |
| find \ | |
| /home/gdrobertslab/lab/${directory} \ | |
| -user mvc002 \ | |
| -type f \ | |
| -not -perm 444 \ | |
| | xargs \ | |
| -d '\n' \ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| InstrumentIDs = {"HWI-M[0-9]{4}$" : ["MiSeq"], | |
| "HWUSI" : ["Genome Analyzer IIx"], | |
| "M[0-9]{5}$" : ["MiSeq"], | |
| "HWI-C[0-9]{5}$" : ["HiSeq 1500"], | |
| "C[0-9]{5}$" : ["HiSeq 1500"], | |
| "HWI-D[0-9]{5}$" : ["HiSeq 2500"], | |
| "D[0-9]{5}$" : ["HiSeq 2500"], | |
| "J[0-9]{5}$" : ["HiSeq 3000"], | |
| "K[0-9]{5}$" : ["HiSeq 3000","HiSeq 4000"], | |
| "E[0-9]{5}$" : ["HiSeq X"], |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Instructions taken from: https://clint.id.au/?p=1900 | |
| srun -c 4 --gres=gpu --account=gdrobertslab --x11 --pty bash | |
| echo "NVBLAS_LOGFILE nvblas.log | |
| NVBLAS_CPU_BLAS_LIB /usr/local/cuda-11.6/lib64/libnvblas.so | |
| NVBLAS_GPU_LIST ALL" > ~/nvblas.conf | |
| module load CUDA/11.5.0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # List scron jobs | |
| scrontab -l | |
| #Edit scron job | |
| scrontab -e | |
| # If scrontab get disabled | |
| scrontab -e | |
| # Delete #DISABLED.... up until $SCRON |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| singularity rstudio | |
| modified from: https://www.rocker-project.org/use/singularity/ | |
| #!/bin/bash | |
| #SBATCH --time=3-00:00:00 | |
| #SBATCH --signal=USR2 | |
| #SBATCH --ntasks=1 | |
| module purge |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| samtools view -H yourFile.bam | \ | |
| grep "\@SQ" | \ | |
| sed 's/^.*SN://g' | \ | |
| cut -f 1 | \ | |
| xargs -I {} \ | |
| -n 1 \ | |
| -P 24 \ | |
| sh -c "samtools mpileup -BQ0 -d 100000 -uf yourGenome.fa -r {} yourFile.bam | bcftools view -vcg - > tmp.{}.vcf" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| DNAnexus app building | |
| source ~/virtualEnvs/dnanexus/bin/activate | |
| dx login # login to server, choose which project to attach to | |
| dx build # build app from the json and associated file(s) | |
| deactivate |