Skip to content

Commit

Permalink
Fixed merge
Browse files Browse the repository at this point in the history
  • Loading branch information
Loyale committed Apr 15, 2016
2 parents 8bf1888 + a4a2fc9 commit 1dfab47
Show file tree
Hide file tree
Showing 8 changed files with 39 additions and 14 deletions.
7 changes: 4 additions & 3 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
Package: cummeRbund
Title: Analysis, exploration, manipulation, and visualization of Cufflinks high-throughput sequencing data.
Version: 2.9.3

Version: 2.13.1
Date: 2013-04-22
Author: L. Goff, C. Trapnell, D. Kelley
Description: Allows for persistent storage, access, exploration, and manipulation of Cufflinks high-throughput sequencing data. In addition, provides numerous plotting functions for commonly used visualizations.
Imports: methods, plyr, BiocGenerics, Biobase
Imports: methods, plyr, BiocGenerics, S4Vectors (>= 0.9.25), Biobase

Depends: R (>= 2.7.0), BiocGenerics (>= 0.3.2), RSQLite, ggplot2, reshape2, fastcluster, rtracklayer, Gviz
Suggests: cluster, plyr, NMFN, stringr, GenomicFeatures, GenomicRanges, rjson
Maintainer: Loyal A. Goff <[email protected]>
Expand Down
6 changes: 4 additions & 2 deletions NAMESPACE
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
importFrom(BiocGenerics, annotation)

import(methods)

#importFrom(graphics, plot)
importFrom(plyr, defaults)

importFrom(BiocGenerics, annotation)
import(S4Vectors)

importFrom(Biobase, featureNames)

exportClasses(CuffSet,
Expand Down
15 changes: 14 additions & 1 deletion R/database-setup.R
Original file line number Diff line number Diff line change
Expand Up @@ -1950,7 +1950,8 @@ readCufflinks<-function(dir = getwd(),
stop("Must provide a dbConn connection")

write("Reading GTF file",stderr())
gr<-import(gtfFile,asRangedData=FALSE)

gr<-import(gtfFile)
gr<-as(gr,"data.frame")
#gr$genome<-genomebuild
colnames(gr)[grepl('^transcript_id$',colnames(gr))]<-'isoform_id'
Expand Down Expand Up @@ -1981,7 +1982,11 @@ readCufflinks<-function(dir = getwd(),
requiredAttribs <- c("gene_id", "transcript_id", "exon_number")

if (verbose) message("Importing ", gtfFile)
<<<<<<< HEAD
tmp <- import(gtfFile, asRangedData=FALSE)
=======
tmp <- import(gtfFile)
>>>>>>> a4a2fc9b30204a4d0b68f44cdbaa7a8b7000efbe

#dispose of unspliced unstranded transcripts
#tmp <- tmp[ which(strand(tmp) %in% c('+','-')) ]
Expand Down Expand Up @@ -2014,7 +2019,11 @@ readCufflinks<-function(dir = getwd(),
tmpS <- split(tmp, values(tmp)$transcript_id)
if(verbose) message('Attempting to create the splicings data.frame')
splicings <- data.frame(
<<<<<<< HEAD
tx_id=rep(1:length(tmpS), elementLengths(tmpS)),
=======
tx_id=rep(1:length(tmpS), elementNROWS(tmpS)),
>>>>>>> a4a2fc9b30204a4d0b68f44cdbaa7a8b7000efbe
exon_rank=as.integer(values(unlist(tmpS))$exon_number),
exon_chrom=as.character(seqnames(unlist(tmpS))),
exon_strand=as.character(strand(unlist(tmpS))),
Expand All @@ -2033,7 +2042,11 @@ readCufflinks<-function(dir = getwd(),

#create the db
if (verbose) message("Creating TranscriptDb")
<<<<<<< HEAD
tmpdb <- makeTranscriptDb(transcripts, splicings, genes=genes)
=======
tmpdb <- makeTxDb(transcripts, splicings, genes=genes)
>>>>>>> a4a2fc9b30204a4d0b68f44cdbaa7a8b7000efbe
if (verbose) message("Use saveFeatures() to save the database to a file")
return(tmpdb)

Expand Down
7 changes: 5 additions & 2 deletions R/methods-CuffData.R
Original file line number Diff line number Diff line change
Expand Up @@ -776,7 +776,8 @@ setMethod("csVolcano",signature(object="CuffData"), .volcano)

p <-ggplot(dat) + geom_point(mapping,na.rm=TRUE,size=0.8) + scale_colour_manual(values = c("black","red")) + facet_grid(sample_1~sample_2)

p<- p + geom_vline(aes(x=0),linetype=2)
p<- p + geom_vline(aes(xintercept=0),linetype=2)


p <- p + theme_bw() + xlab(bquote(paste(log[2],"(fold change)",sep=""))) + ylab(bquote(paste(-log[10],"(p value)",sep="")))

Expand Down Expand Up @@ -961,7 +962,9 @@ setMethod("MDSplot",signature(object="CuffData"),.MDSplot)
if(showPoints){
plot<- plot + geom_point(alpha=.4, size=0.8, aes(label=obsnames))
}
plot <- plot + geom_hline(aes(0), size=.2) + geom_vline(aes(0), size=.2) #+ geom_text(aes(label=shoutout),size=2,color="red")

plot <- plot + geom_hline(aes(yintercept=0), size=.2) + geom_vline(aes(xintercept=0), size=.2) #+ geom_text(aes(label=shoutout),size=2,color="red")

datapc <- data.frame(varnames=rownames(PC$rotation), PC$rotation)
mult <- min(
(max(dat[,y]) - min(dat[,y])/(max(datapc[,y])-min(datapc[,y]))),
Expand Down
4 changes: 3 additions & 1 deletion R/methods-CuffFeatureSet.R
Original file line number Diff line number Diff line change
Expand Up @@ -1146,7 +1146,9 @@ setMethod("MDSplot",signature(object="CuffFeatureSet"),.MDSplot)
if(showPoints){
plot<- plot + geom_point(alpha=.4, size=0.8, aes(label=obsnames))
}
plot <- plot + geom_hline(aes(0), size=.2) + geom_vline(aes(0), size=.2) #+ geom_text(aes(label=shoutout),size=2,color="red")

plot <- plot + geom_hline(aes(yintercept=0), size=.2) + geom_vline(aes(xintercept=0), size=.2) #+ geom_text(aes(label=shoutout),size=2,color="red")

datapc <- data.frame(varnames=rownames(PC$rotation), PC$rotation)
mult <- min(
(max(dat[,y]) - min(dat[,y])/(max(datapc[,y])-min(datapc[,y]))),
Expand Down
5 changes: 3 additions & 2 deletions R/methods-CuffGene.R
Original file line number Diff line number Diff line change
Expand Up @@ -171,8 +171,9 @@ setMethod("genePlot",signature(object="CuffGene"),.plot)
#print(dat)
p<-ggplot(dat,aes(x="",y=fpkm,fill=tracking_id))

p<- p + geom_bar(stat="identity",position="fill",line="black")


p<- p + geom_bar(stat="identity",position="fill",color="black")

p<- p + coord_polar(theta='y')

p<-p + scale_fill_hue(l=50,h.start=200) + scale_color_hue(l=50,h.start=200) + theme_bw()
Expand Down
6 changes: 4 additions & 2 deletions R/methods-CuffSet.R
Original file line number Diff line number Diff line change
Expand Up @@ -764,11 +764,13 @@ setMethod("getSig",signature(object="CuffSet"),.getSig)
sig$testResult<-0
sig$testResult[sig$q_value<=alpha]<-1

fieldsNeeded<-c('gene_id','testName','testResult')

fieldsNeeded<-c(slot(object,level)@idField,'testName','testResult')
sig<-sig[,fieldsNeeded]

#recast
sig.table<-acast(sig,gene_id~testName,value='testResult')
sig.table<-acast(sig,as.formula(paste(slot(object,level)@idField,"~testName")),value='testResult')


#remove genes that do not reject null in any test
sig.table<-sig.table[rowSums(sig.table,na.rm=T)>0,]
Expand Down
3 changes: 2 additions & 1 deletion README
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,11 @@ Authors:
Maintainer:
- Loyal A. Goff <[email protected]>


Creative Contributions & Support:
- John L. Rinn (2)
- Manolis Kellis (1)
- Ron Hart (3)
- Ron Hart (3)
- David Hendrickson (2)

Affiliations:
Expand Down

0 comments on commit 1dfab47

Please sign in to comment.