kevinblighe / EnhancedVolcano

Publication-ready volcano plots with enhanced colouring and labeling
399 stars 81 forks source link

beginners question #62

Closed mocherry closed 3 years ago

mocherry commented 3 years ago

Dear Kevin,

I came across EnhancedVolcano and like it a lot. However, not being firm with R I am not able to solve the following task: I am using selectLab = c('Traf2','Bcl3', ...) to just label a selection of genes from my data. Now I would like the points for these genes be bigger than the others. I played around with: 4.12 Highlighting key variables via custom point sizes but do not get it to work with just the list of genes I selected. Here is the basic script I am using. It would be great, if you could point me in the right direction: library(EnhancedVolcano) mydata <- read.csv("file.csv", sep=";", header = TRUE, row.names = 1) df <- data.frame(mydata) EnhancedVolcano(df, lab = rownames(df), x = 'log2FoldChange', y = 'pvalue', selectLab = c('Traf2','Bcl3',...), pCutoff = 0.1, FCcutoff = 1.3, title = 'Title', pointSize = 1.0, labSize = 4.0, labFace = 'bold', subtitle = "Differential expression", xlim = c(-10, 10))

Thanks and best Matthias

kevinblighe commented 3 years ago

Hey Matthias, to modify the point sizes for a few genes of interest, you have to supply a custom vector of sizes to the pointSize parameter. There is an example in the vignette. If you can, first, try to complete that part of the vignette, then you should understand better how to achieve what you want.