plotSmoothers {tradeSeq} | R Documentation

## Plot the log-transformed counts and the fitted values for a particular gene along all lineages

### Description

Plot the smoothers estimated by `tradeSeq`.

### Usage

    plotSmoothers(models, ...)

    ## S4 method for signature 'gam'
    plotSmoothers(models, nPoints = 100, lwd = 2,
      size = 2/3, xlab = "Pseudotime", ylab = "Log(expression + 1)",
      border = TRUE, alpha = 1)

    ## S4 method for signature 'SingleCellExperiment'
    plotSmoothers(models, counts, gene,
      nPoints = 100, lwd = 2, size = 2/3, xlab = "Pseudotime",
      ylab = "Log(expression + 1)", border = TRUE, alpha = 1)

### Arguments

`models` | Either the `SingleCellExperiment` object obtained after running `fitGAM`, or the specific GAM model for the corresponding gene, if working with the list output of `tradeSeq`.
`...` | parameters including:
`nPoints` | The number of points used to extraplolate the fit
`lwd` | Line width of the smoother. Passed to `geom_line`
`size` | Character expansion of the data points. Passed to `geom_point`
`xlab` | x-axis label. Passed to `labs`
`ylab` | y-axis label. Passed to `labs`
`border` | logical: should a white border be drawn around the mean smoother.
`alpha` | Numeric between 0 and 1, determines the transparancy of data points, see `scale_color_viridis_d`.
`counts` | The matrix of gene expression counts.
`gene` | Gene name of gene to plot.

### Value

A `ggplot` object

### Examples

    data(gamList, package = "tradeSeq")
    plotSmoothers(gamList[[4]])

[Package tradeSeq version 1.0.1 Index]