## NOTE: toy example with few reads & genes to illustrate code usage
## Results with complete data are much more interesting!
data(K562.r1l1)
data(hg19DB)
#Pre-process
bam0 <- rmShortInserts(K562.r1l1, isizeMin=100)
pbam0 <- procBam(bam0)
#Estimate distributions, get path counts
distrs <- getDistrs(hg19DB,bam=bam0,readLength=75)
pc <- pathCounts(pbam0, DB=hg19DB)
#Set prior distrib on model space
mprior <- modelPrior(hg19DB, maxExons=40, smooth=FALSE)
#Fit model
denovo <- calcDenovo(distrs,targetGenomeDB=hg19DB,pc=pc,readLength=75,priorq=3,mprior=mprior,minpp=0)
head(names(denovo))
denovo[['6499']]
posprob(denovo[['6499']])
#Get estimates
eset <- denovoExpr(denovo, pc=pc, rpkm=TRUE, minProbExpr=0.5)
head(exprs(eset))
head(fData(eset))
Run the code above in your browser using DataLab