# FeaturePlot from Seurat: change its title

FeaturePlot is a function in Seurat package.

And in the vignette it is written that if we specify parameter do.return = TRUE it should return ggplot2 object. It is not working. My goal here is just to change the title of the plot. In case of violin plot I can do the following:

VlnPlot(object = seurat_object, features.plot = id, do.return = TRUE) + labs(title = endothelial_symbols[1])


But with FeaturePlot similar code fails to work:

FeaturePlot(object = seurat_object, features.plot = id, cols.use = c("grey", "blue"),
reduction.use = "tsne", do.return = TRUE) + labs(title = endothelial_symbols[1])


Giving the error:

Error in FeaturePlot(object = seurat_object, features.plot = id, cols.use = c("grey", : non-numeric argument to binary operator

Any suggestions would be greatly appreciated.

p <- FeaturePlot(object = seurat_object, features.plot = id, cols.use = c("grey", "blue"),

• This can be “simplified” to lapply(p, +, labs(title = endothelial_symbols[1])). – Konrad Rudolph Jun 13 '18 at 12:49