|
|
@@ -12,7 +12,7 @@ |
|
|
|
#2 Set up |
|
|
|
# |
|
|
|
##2.1 load package |
|
|
|
library(cn.mops) |
|
|
|
library(cn.mops) #cn.mops_1.16.2 |
|
|
|
# |
|
|
|
##2.2 load options |
|
|
|
# |
|
|
@@ -35,12 +35,11 @@ if("--help" %in% args) { |
|
|
|
--TumorSampleID=the name of the TUMOR sample - string |
|
|
|
--bed_file=BED (Browser Extensible Data) lines have four required fields included chr, start, end and gene annotation. - string |
|
|
|
--workDir=working directory - character |
|
|
|
--outputDir=where you want to output the pictures - character |
|
|
|
--help - print this text |
|
|
|
|
|
|
|
|
|
|
|
Example: |
|
|
|
Rscript cn.mops.R --Tumor=TumorSample.bam --Normal=NormalSample.bam --TumorSampleID=TumorSampleID --bed_file=bedFile --workDir=./ --outputDir=./ \n\n") |
|
|
|
Rscript cn.mops.R --Tumor=TumorSample.bam --Normal=NormalSample.bam --TumorSampleID=TumorSampleID --bed_file=bedFile --workDir=./ \n\n") #--outputDir=./ |
|
|
|
|
|
|
|
q(save="no") |
|
|
|
} |
|
|
@@ -87,13 +86,6 @@ if(is.null(args$workDir)) { |
|
|
|
workDir=args$workDir |
|
|
|
} |
|
|
|
# |
|
|
|
## Arg6 default |
|
|
|
if(is.null(args$outputDir)) { |
|
|
|
stop("outputDir is missing") |
|
|
|
}else{ |
|
|
|
outputDir=args$outputDir |
|
|
|
} |
|
|
|
# |
|
|
|
#3 Run cn.mops |
|
|
|
# Tumor <- c("Illumina_pt2_B1700.chr20_X.sorted.deduped.bam") |
|
|
|
# Normal <- c("Illumina_pt2_B17NC.chr20_X.sorted.deduped.bam") |
|
|
@@ -141,7 +133,7 @@ Res <- data.frame(sampleName=Res$sampleName,chr=Res$chr, |
|
|
|
CN=Res$CN) |
|
|
|
# |
|
|
|
##3.4 Output |
|
|
|
write.table(Res,paste0(outputDir,"/",TumorSampleID,"cn.mops.res.txt"),sep="\t", |
|
|
|
write.table(Res,paste0(TumorSampleID,"cn.mops.res.txt"),sep="\t", |
|
|
|
col.names=T,row.names=F,quote=F) |
|
|
|
|
|
|
|
|