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
dta <- read.csv("file:///E:/LAB_DATA/00-LabData/Lab/00--Archive/TCGA_DNA_met/27k_Set2/liver/liver.set2.boxplot..csv", | |
header = T) | |
dta <- read.csv("file:///E:/LAB_DATA/00-LabData/Lab/00--Archive/TCGA_DNA_met/423CpGs_set12357/423CpGs.boxplot.2.csv", header = T) | |
dim(dta) | |
################## | |
types <- data.frame(c(rep("breast.C",793),rep("breast.N",97), | |
rep("colon.C",313),rep("colon.N",38), | |
rep("kidney.C",324),rep("kidney.N",160), | |
rep("liver.C",377),rep("liver.N",50), |
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
# USING "ggplot2" and "for loop" | |
types <- data.frame(c(rep("breast.C",793),rep("breast.N",97), | |
rep("colon.C",313),rep("colon.N",38), | |
rep("kidney.C",324),rep("kidney.N",160), | |
rep("liver.C",377),rep("liver.N",50), | |
rep("lung.C",473),rep("lung.N",32), | |
rep("prostate.C",502),rep("prostate.N",50))) | |
colnames(types) <- "types" |
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
# Ubuntu 16.04 | |
# R-3.4.1 | |
1. Download R source package | |
2. Install dependencies | |
$ sudo apt-get install fort77 xorg-dev liblzma-dev libblas-dev gfortran gcc-multilib gobjc++ aptitude libreadline-dev | |
3. Install 'open-blas' |
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
library(WGCNA) | |
allowWGCNAThreads() | |
################################################################################# | |
# Loading expression data | |
setwd('/home/bio0/00-NGS/TCGA_met/data') | |
set1 <- read.csv("600samples.cosmic170k.csv", header = T, row.names = 1) | |
all.set <- read.csv("2400samples.27k.set2.2.csv", header = T, row.names = 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
library(limma) | |
library(gplots) | |
library(FactoMineR) | |
########################################## | |
# Data importing | |
setwd("D:/00-LabData/Lab/Experiments/2017-01/EpiDriver/T_cell/") | |
dta<-read.csv("EpiDriver_Tcells_biasCorrection_Final_StdQt.csv", row.names = 1, header = T) |
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
102_103 insC 4 | |
102 delC 2 | |
101_102 delCC 2 | |
102 C>G 1 | |
101 C>T 4 | |
98_99 insT 1 | |
98 delC 2 | |
98 delC 2 | |
98 C>T 2 | |
97 delT 2 |
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
grep -Po 'c..*' COSMIC_TP53_MUT | sed 's/;/\t/g' | cut -f 1,3 | sed 's/CNT=//g'| grep -Po 'c.\d*(\_?\-?\+?)\d*' > position | |
grep -Po 'c..*' COSMIC_TP53_MUT | sed 's/;/\t/g' | cut -f 1,3 | sed 's/CNT=//g'| grep -Po '[a-zA-Z]*\>?[a-zA-Z]*\t' > sequence | |
grep -Po 'c..*' COSMIC_TP53_MUT | sed 's/;/\t/g' | cut -f 3 | sed 's/CNT=//g' > count | |
paste position sequence count | sed 's/c.//g' > COSMIC_TP53_MUT_all |
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
17 7676265 COSM45241 AA A . . GENE=TP53;STRAND=-;CDS=c.103delT;AA=p.L35fs*9;CNT=1 | |
17 7676266 COSM96588 A AG . . GENE=TP53;STRAND=-;CDS=c.102_103insC;AA=p.P36fs*7;CNT=4 | |
17 7676266 COSM2745164 AG A . . GENE=TP53;STRAND=-;CDS=c.102delC;AA=p.L35fs*9;CNT=2 | |
17 7676266 COSM48976 AGG A . . GENE=TP53;STRAND=-;CDS=c.101_102delCC;AA=p.P34fs*8;CNT=2 | |
17 7676267 COSM5387432 G C . . GENE=TP53;STRAND=-;CDS=c.102C>G;AA=p.P34P;CNT=1 | |
17 7676268 COSM43672 G A . . GENE=TP53;STRAND=-;CDS=c.101C>T;AA=p.P34L;CNT=4 | |
17 7676270 COSM4765600 G GA . . GENE=TP53;STRAND=-;CDS=c.98_99insT;AA=p.P36fs*7;CNT=1 | |
17 7676270 COSM1172527 GG G . . GENE=TP53;STRAND=-;CDS=c.98delC;AA=p.L35fs*9;CNT=2 | |
17 7676270 COSM22928 GG G . . GENE=TP53;STRAND=-;CDS=c.98delC;AA=p.L35fs*9;CNT=2 | |
17 7676271 COSM4272154 G A . . GENE=TP53;STRAND=-;CDS=c.98C>T;AA=p.S33F;CNT=2 |
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
#!/bin/bash | |
export LC_ALL=C | |
printf "*** SNVcounter\n | |
*** 'samtools, bcftools, and bedtools' must be installed to run this script\n | |
*** Prepare 'reference fasta' and 'SNV list' in BED format\n | |
*** merge consecutive SNVs using\n | |
*** 'sort -k1,1 -k2,2n SNV.bed | mergeBed -c 4 -o collapse'\n | |
*** usage : ./SNVcounter Input.Bam Reference.Fasta mergedSNV.bed\n\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
#!/bin/bash | |
cat $1 $2 | muscle |fasta_formatter | paste - - - - | cut -f 1,2,4 | sed 's/>M.//g' | |
cat $1 $2 | muscle -clw | grep "*" | sed 's/^ *//g;s/ /!/g' | tr '\n' ' ' | sed 's/ //g' | grep -bo "!" | tr '\n' ' ' | |
printf "\n" |