Description Usage Arguments Value Examples

View source: R/newINSPEcT-functions.R

The function newINSPEcT creates a new instance of the class INSPEcT provided the experimental time points, expression data (like RPKMs) of mature and eventually nascent RNA. For the nascent analysis, it is also requires a collecting time and the scaling factor to normalize the nascent RNA-seq libraries. This latter parameter can also be calculated by the function itself if both exonic and intronic expression data are provided; otherwise it must be given as an input and it is essential to guarantee the robustness of the analysis.

1 2 3 4 5 6 | ```
newINSPEcT(tpts, labeling_time = NULL, nascentExpressions = NULL,
matureExpressions, BPPARAM = bpparam(), totalMedianNorm = TRUE,
labeledMedianNorm = FALSE, totalSF = NULL, labeledSF = NULL,
totalQuantileNorm = FALSE, labeledQuantileNorm = FALSE,
simulatedData = FALSE, degDuringPulse = FALSE, Dmin = 1e-06,
Dmax = 10, genesFilter = TRUE)
``` |

`tpts` |
A vector of time points, one for each sample |

`labeling_time` |
A number, lenght of the Nascent pulse |

`nascentExpressions` |
A list which contains exons and introns expression matrices and variances for the nascent RNA |

`matureExpressions` |
A list which contains exons and introns expression matrices and variances for the mature RNA |

`BPPARAM` |
Configuration for BiocParallel parallelization. By default is set to bpparam() |

`totalMedianNorm` |
A logical to perform median normalization over total RNA exons rpkms, it will apply also on introns |

`labeledMedianNorm` |
A logical to perform median normalization over Nascent RNA exons rpkms, it will apply also on introns |

`totalSF` |
A vector storing user defined normalization scale over Total RNA exons and introns rpkms |

`labeledSF` |
A vector storing user defined normalization scale over Nascent RNA exons and introns rpkms |

`totalQuantileNorm` |
A logical to perform to perform median normalization over total RNA exons rpkms, it will apply also on introns |

`labeledQuantileNorm` |
A logical to perform to perform median normalization over Nascent RNA exons rpkms, it will apply also on introns |

`simulatedData` |
A logical, set to TRUE in case the analysis is on simulated data |

`degDuringPulse` |
A logical, set to TRUE in case of a long labelling time. Also degradation of newly synthesized transcripts will be taken into account |

`Dmin` |
A numerical, it is the lower bound of the degradation rate domain for the prior optimization |

`Dmax` |
A numerical, it is the upper bound of the degradation rate domain for the prior optimization |

`genesFilter, ` |
A logical which, if TRUE, filters out genes which have no signal in at least 2/3 of the time points in each feature |

An object of class INSPEcT with a first estimation of the rates which can be accessed by the method `ratesFirstGuess`

.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 | ```
require(TxDb.Mmusculus.UCSC.mm9.knownGene)
txdb <- TxDb.Mmusculus.UCSC.mm9.knownGene
data('allcounts', package='INSPEcT')
matureCounts<-allcounts$mature
testGenes<-rownames(matureCounts$exonsCounts)
require(TxDb.Mmusculus.UCSC.mm9.knownGene)
txdb<-TxDb.Mmusculus.UCSC.mm9.knownGene
exonsDB<-reduce(exonsBy(txdb ,'gene'))
exonsDB<-exonsDB[elementNROWS(range(exonsDB))==1]
intronsDB<-psetdiff(unlist(range(exonsDB)),exonsDB)
intronsDB<-intronsDB[elementNROWS(intronsDB)>0]
exWdths<-sapply(width(exonsDB),sum)
intWdths<-sapply(width(intronsDB),sum)
exWdths<-exWdths[testGenes]
intWdths<-intWdths[testGenes]
totalLS<-colSums(matureCounts$
stat[c('Assigned_Exons','Assigned_Introns'),,drop=FALSE])
tpts<-c(0,1/6,1/3,1/2,1,1.5,2,4,8,12,16)
expDes<-rep(tpts,3)
matExp_DESeq2<-quantifyExpressionsFromTrCounts(libsize=totalLS
,exonsWidths=exWdths
,intronsWidths=intWdths
,allcounts=matureCounts
,DESeq2=TRUE
,experimentalDesign=expDes)
matureInspObj<-newINSPEcT(tpts=tpts
,labeling_time=NULL
,nascentExpressions=NULL
,matureExpressions=matExp_DESeq2)
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.