heatmap,PredictionProfile,missing-method {kebabs} | R Documentation

## Heatmap Methods

### Description

Create a heat map of prediction profiles

### Usage

    ## S4 method for signature 'PredictionProfile,missing'
    heatmap(x, Rowv = TRUE, add.expr,
      margins = c(5, 5), RowSideColors = NULL,
      cexRow = max(min(35/nrow(x@profiles), 1), 0.1),
      cexCol = max(min(35/ncol(x@profiles), 1), 0.1), main = NULL,
      dendScale = 1, barScale = 1, startPos = 1, endPos = ncol(x@profiles),
      labels = NULL, windowSize = 1, ...)

### Arguments

`x` | prediction profile of class `PredictionProfile`.
`Rowv` | determines the row order of the plot. When set to `TRUE` the profile rows are clustered via hierarchical clustering and a row dendrogram is plotted. When set to `FALSE, NA or NULL` the order is corresponds to the order of the sequences in the profile. If this parameter has a value of `random` rows are ordered randomly, for `decision` the ordering is according to decreasing decision values. A user-defined order can be specified through a numeric vector of indices. Default=TRUE
`add.expr` | largely analogous to the standard `heatmap` function.
`margins` | largely analogous to the standard `heatmap` function. Default=c(5,5)
`RowSideColors` | a vector of color values specifying the colors for the side bar. Default=NULL
`cexRow` | largely analogous to the standard `heatmap` function. When set to 0 the row labels are suppressed. Default=defined dependent on number of profile rows
`cexCol` | largely analogous to the standard `heatmap` function. When set to 0 the column labels are suppressed. Default=defined dependent on number of profile columns
`main` | largely analogous to the standard `heatmap` function.
`dendScale` | factor scaling the width of the row dendrogram; values have to be larger than 0 and not larger than 2. Default=1
`barScale` | factor scaling the width of the label color bar. Values have to be larger than 0 and not larger than 4. Default=1
`startPos` | start sequence position. Together with the parameter `endPos` a subset of sequence positions can be selected for the heatmap. Default=1
`endPos` | end sequence position (see also `startPos`). Default=maximum sequence length in the profile.
`labels` | a numeric vector, character vector or factor specifying the labels for the sequences in the profile. If this parameter is different from NULL the labels are plotted as side bar using the colors specified in the parameter `RowSideColors`. Default=NULL
`windowSize` | numerical value specifying the window size of an optional sliding window averaging of the prediction profiles. The value must be larger than 0. Even values are changed internally to odd values by adding 1. Default=1
`...` | additional parameters which are passed to the `image` method transparently.

### Details

The `heatmap` function provides plotting of heatmaps from prediction profiles with various possibilities for sample (=row) ordering (see parameter `Rowv`). The heatmap is shown together with an optional color sidebar showing the labels and an optional row cluster dendrogram when hierarchical clustering defines the row order. For long sequences the heatmap can be restricted to a subset of positions. Additionally smoothing can be applied to the prediction profiles through sliding window averaging. Through smoothing important regions can become better visible.

### Value

Invisibly, a cluster dendrogram.

### Author(s)

Johannes Palme <kebabs@bioinf.jku.at>

### References

http://www.bioinf.jku.at/software/kebabs
(Bodenhofer, 2009) – U. Bodenhofer, K. Schwarzbauer, M. Ionescu and S. Hochreiter. Modelling position specificity in sequence kernels by fuzzy equivalence relations.
(Mahrenholz, 2011) – C.C. Mahrenholz, I.G. Abfalter, U. Bodenhofer, R. Volkmer and S. Hochreiter. Complex networks govern coiled-coil oligomerizations - predicting and profiling by means of a machine learning approach.
J. Palme, S. Hochreiter, and U. Bodenhofer (2015) KeBABS: an R package for kernel-based analysis of biological sequences. Bioinformatics, 31(15):2574-2576, 2015. DOI: 10.1093/bioinformatics/btv176.

### See Also

`getPredictionProfile`

### Examples

    ## load coiled coil data
    data(CCoil)

    ## define annotation specific gappy pair kernel
    gappya <- gappyPairKernel(k=1,m=11, annSpec=TRUE)

    ## train model
    model <- kbsvm(x=ccseq, y=as.numeric(yCC), kernel=gappya,
                   pkg="e1071", svm="C-svc", cost=15)

    ## generate prediction profiles
    predProf <- getPredictionProfile(ccseq, gappya,
                           featureWeights(model), modelOffset(model))

    ## show prediction profiles
    predProf

    ## Not run:
    ## plot heatmap for the prediction profiles - random ordering of samples
    heatmap(predProf, Rowv="random", main="Prediction Profiles", labels=yCC,
    RowSideColors=c("blue", "red"), cexRow=0.15, cexCol=0.3)

    ## plot heatmap for the prediction profiles - ordering by decision values
    heatmap(predProf, Rowv="decision", main="Prediction Profiles", labels=yCC,
    RowSideColors=c("blue", "red"), cexRow=0.15, cexCol=0.3)

    ## plot heatmap for the prediction profiles - with hierarchical clustering
    heatmap(predProf, Rowv=TRUE, main="Prediction Profiles", labels=yCC,
    RowSideColors=c("blue", "red"), cexRow=0.15, cexCol=0.3)

    ## End(Not run)

[Package kebabs version 1.16.0 Index]