Skip to content

Commit

Permalink
redundant code removed
Browse files Browse the repository at this point in the history
  • Loading branch information
anatolydryga committed Aug 25, 2015
1 parent 4414204 commit 51c8a76
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
6 changes: 0 additions & 6 deletions R/intSiteRetriever.R
Original file line number Diff line number Diff line change
Expand Up @@ -162,12 +162,6 @@ getMRCs <- function(sample_ref, conn, numberOfMRCs=3) {
ref_genome <- sites.metadata$refGenome[1] # all the same

mrcs <- get_N_MRCs(sites_meta, get_reference_genome(ref_genome), numberOfMRCs)

#keep output consistant across functions
mrcs$siteID <- as.numeric(mrcs$siteID)
mrcs$position <- as.numeric(mrcs$position)
mrcs$strand <- as.character(mrcs$strand)
mrcs$chr <- as.character(mrcs$chr)

merge(mrcs, sites.metadata[c("siteID", "sampleName", "refGenome")])
}
Expand Down
4 changes: 2 additions & 2 deletions R/random_site.R
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,8 @@ get_random_positions <- function(siteIDs, reference_genome, gender,
data_frame(
"siteID" = rep(x,number_of_positions),
"chr" = as.character(cuts),
"strand"=as.character(cut(sign(rands), breaks=c(-1,0,1), labels=c("-", "+"), include.lowest=T)),
"position"=abs(rands) - cs[match(cuts, names(chr_len))])
"strand" = as.character(cut(sign(rands), breaks=c(-1,0,1), labels=c("-", "+"), include.lowest=T)),
"position" = abs(rands) - cs[match(cuts, names(chr_len))])
})

.Random.seed <- seed #resetting the seed
Expand Down

0 comments on commit 51c8a76

Please sign in to comment.