Mercurial > repos > davidvanzessen > shm_csr
comparison shm_csr.r @ 62:aa8d37bd1930 draft
Uploaded
author | davidvanzessen |
---|---|
date | Tue, 05 Dec 2017 10:57:13 -0500 |
parents | 77a7ac76c7b9 |
children |
comparison
equal
deleted
inserted
replaced
61:275e759e7985 | 62:aa8d37bd1930 |
---|---|
8 genes = unlist(strsplit(args[2], ",")) | 8 genes = unlist(strsplit(args[2], ",")) |
9 outputdir = args[3] | 9 outputdir = args[3] |
10 empty.region.filter = args[4] | 10 empty.region.filter = args[4] |
11 setwd(outputdir) | 11 setwd(outputdir) |
12 | 12 |
13 dat = read.table(input, header=T, sep="\t", fill=T, stringsAsFactors=F) | 13 #dat = read.table(input, header=T, sep="\t", fill=T, stringsAsFactors=F) |
14 | |
15 dat = data.frame(fread(input, sep="\t", header=T, stringsAsFactors=F)) #fread because read.table suddenly skips certain rows... | |
14 | 16 |
15 if(length(dat$Sequence.ID) == 0){ | 17 if(length(dat$Sequence.ID) == 0){ |
16 setwd(outputdir) | 18 setwd(outputdir) |
17 result = data.frame(x = rep(0, 5), y = rep(0, 5), z = rep(NA, 5)) | 19 result = data.frame(x = rep(0, 5), y = rep(0, 5), z = rep(NA, 5)) |
18 row.names(result) = c("Number of Mutations (%)", "Transition (%)", "Transversions (%)", "Transitions at G C (%)", "Targeting of G C (%)") | 20 row.names(result) = c("Number of Mutations (%)", "Transition (%)", "Transversions (%)", "Transitions at G C (%)", "Targeting of G C (%)") |