## 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)
Run the code above in your browser using DataLab