Mercurial > repos > davidvanzessen > argalaxy_tools
diff report_clonality/RScript.r @ 17:da95be204ebc draft
Uploaded
author | davidvanzessen |
---|---|
date | Wed, 21 Dec 2016 05:57:31 -0500 |
parents | 02efa5764a0a |
children | 5d11c9139a55 |
line wrap: on
line diff
--- a/report_clonality/RScript.r Tue Dec 20 09:06:51 2016 -0500 +++ b/report_clonality/RScript.r Wed Dec 21 05:57:31 2016 -0500 @@ -594,7 +594,10 @@ res = merge(res, clone_table, by="paste", all=T) } - res[is.na(res)] = 0 + res[is.na(res)] = 0 + + write.table(res, file=paste("raw_clonality_", sample_id, ".csv", sep=""), sep=",",quote=F,row.names=F,col.names=F) + infer.result = infer.clonality(as.matrix(res[,2:ncol(res)])) #print(infer.result) @@ -607,7 +610,7 @@ colnames(coincidence.table) = c("Coincidence Type", "Raw Coincidence Freq") write.table(coincidence.table, file=paste("lymphclon_coincidences_", sample_id, ".csv", sep=""), sep=",",quote=F,row.names=F,col.names=T) } - } else { + } else if(clonality_method == "old") { clonalFreq = data.frame(data.table(clonalityFrame)[, list(Type=.N), by=c("Sample", "clonaltype")]) #write files for every coincidence group of >1