getter_setter_functions {FRASER} | R Documentation

## Getter/Setter functions

### Description

This is a collection of small accessor/setter functions for easy access to the values within the FRASER model.

### Usage

    featureExclusionMask(fds, type = currentType(fds))

    featureExclusionMask(fds, type = currentType(fds)) <- value

    rho(fds, type = currentType(fds))

    zScores(fds, type = currentType(fds), byGroup = FALSE, ...)

    pVals(fds, type = currentType(fds), level = "site", dist = "BetaBinomial", ...)

    padjVals(fds, type = currentType(fds), dist = c("BetaBinomial"), ...)

    predictedMeans(fds, type = currentType(fds))

    deltaPsiValue(fds, type = currentType(fds))

    currentType(fds)

    currentType(fds) <- value

    pseudocount(value = NULL)

    hyperParams(fds, type = currentType(fds), all = FALSE)

    bestQ(fds, type = currentType(fds))

    dontWriteHDF5(fds)

    dontWriteHDF5(fds) <- value

    verbose(fds)

    verbose(fds) <- value

### Arguments

`fds` | An FraserDataSet object.
`type` | The type of psi (psi5, psi3 or psiSite)
`value` | The new value to be assigned.
`byGroup` | If TRUE, aggregation by donor/acceptor site will be done.
`...` | Internally used parameteres.
`level` | Indicates if the retrieved p values should be adjusted on the donor/acceptor site-level (default) or if unadjusted junction-level p values should be returned.
`dist` | Distribution for which the p-values should be extracted.
`all` | Logical value indicating whether `hyperParams(fds)` should return the results of all evaluated parameter combinations or only for the optimal parameter combination.

### Value

A (delayed) matrix or vector dependent on the type of data retrieved.

### Functions

- `featureExclusionMask`: Retrieves a logical vector indicating for each junction whether it is included or excluded during the fitting procedure.

- `featureExclusionMask<-`: To remove certain junctions from being used in the train step of the encoding dimension we can set the `featureExclusion` vector to `FALSE`. This can be helpfull if we have local linkage between features which we do not want to model by the autoencoder.

- `rho`: Returns the fitted rho values for the beta-binomial distribution

- `zScores`: This returns the calculated z-scores.

- `pVals`: This returns the calculated p-values.

- `padjVals`: This returns the adjusted p-values.

- `predictedMeans`: This returns the fitted mu (i.e. psi) values.

- `deltaPsiValue`: Returns the difference between the observed and the fitted psi values.

- `currentType`: Returns the psi type that is used within several methods in the FRASER package.

- `currentType<-`: Sets the psi type that is to be used within several methods in the FRASER package.

- `pseudocount`: Sets and returns the pseudo count used within the FRASER fitting procedure.

- `hyperParams`: This returns the results of the hyperparameter optimization NULL if the hyperparameter opimization was not run yet.

- `bestQ`: This returns the optimal size of the latent space according to the hyperparameter optimization or a simple estimate of about a tenth of the number of samples if the hyperparameter opimization was not run yet.

- `dontWriteHDF5`: Gets the current value of whether the assays should be stored as hdf5 files.

- `dontWriteHDF5<-`: Sets whether the assays should be stored as hdf5 files.

- `verbose`: Dependend on the level of verbosity the algorithm reports more or less to the user. 0 means being quiet and 10 means everything.

- `verbose<-`: Sets the verbosity level to a value between 0 and 10. 0 means being quiet and 10 means reporting everything.

### Examples

    fds <- createTestFraserDataSet()

    # should assays be saved as hdf5?
    dontWriteHDF5(fds)
    dontWriteHDF5 <- TRUE

    # get/set the splice metric for which results should be retrieved
    currentType(fds) <- "psi5"
    currentType(fds)

    # get fitted parameters
    bestQ(fds)
    predictedMeans(fds)
    rho(fds)

    # get statistics
    pVals(fds)
    padjVals(fds)
    zScores(fds)

    # set and get pseudocount
    pseudocount(4L)
    pseudocount()

    # retrieve or set a mask to exclude certain junctions in the fitting step
    featureExclusionMask(fds, type="psiSite") <- sample(
            c(FALSE, TRUE), nrow(mcols(fds, type="psiSite")), replace=TRUE)
    featureExclusionMask(fds, type="psiSite")

    # controlling the verbosity level of the output of some algorithms
    verbose(fds) <- 2
    verbose(fds)

[Package FRASER version 1.0.2 Index]