modelRates {INSPEcT} | R Documentation

## Launch the modeling process

### Description

Launch the modeling process with parameters set with `modelingParams`

This method model the synthesis, degradation and processing rates after their estimation by the constructor function `newINSPEcT`. Estimated rates are not guaranteed to optimally describes provided input data yet. To this purpose, modeled rates can be generated and genes can be assigned to a transcriptional regulatory mechanism. Modeled rates can be accessed via the method `viewModelRates` and gene classification according to the regulatory mechanism can be accessed by `geneClass`. The modeling procedure can be set by the user changing the parameters via `modelingParams`

### Usage

    modelRates(object, seed = NULL, BPPARAM = bpparam(), verbose = NULL)

    ## S4 method for signature 'INSPEcT'
    modelRates(object, seed = NULL,
      BPPARAM = bpparam(), verbose = NULL)

### Arguments

`object` | An object of class INSPEcT
`seed` | A numeric, indicatindg the seed to be set for reproducible results
`BPPARAM` | Parallelization parameters for bplapply. By default bpparam()
`verbose` | Either NULL or logical. If logical indicates whether to output some text during computation or not, if NULL it takes the information from the object (see `modelingParams`) (Default: NULL)

### Details

When modeling many genes, parallelization is strongly suggested to reduce computational time. Since all genes run independently, the computational time is diveded by the number of cores used/available. However, when modeling more than 500 genes, it may happen that a single gene returns an error that escapes the try/catch controls of INSPEcT. With the parallel mode, the error will propagate on all genes that have been computed with the same processor (or core). To avoid this, the computation could be splitted in chunks and the whole data set can be obtaied by combining the chunks (see Examples).

### Value

An object of class INSPEcT with modeled rates

### See Also

`viewModelRates`, `geneClass`, `modelingParams`

### Examples

    if( Sys.info()["sysname"] != "Windows" ) {
    	nascentInspObj10 <- readRDS(system.file(package='INSPEcT', 'nascentInspObj10.rds'))
    	## models removal
    	nascentInspObjThreeGenes <- removeModel(nascentInspObj10[1:3])
    	nascentInspObjThreeGenes <- modelRates(nascentInspObjThreeGenes, seed=1, BPPARAM=SerialParam())
    	## view modeled synthesis rates
    	viewModelRates(nascentInspObjThreeGenes, 'synthesis')
    	## view gene classes
    	geneClass(nascentInspObjThreeGenes)
    }

[Package INSPEcT version 1.12.2 Index]