hms-dbmi / UpSetR

An R implementation of the UpSet set visualization technique published by Lex, Gehlenborg, et al..
https://cran.rstudio.com/web/packages/UpSetR
Other
753 stars 153 forks source link

possible bug? #252

Open marwa38 opened 1 year ago

marwa38 commented 1 year ago

Hi team I think something weird is happening. I have checked my input Excel file (attached) to find the total is different for some variables.

Check for example stimulus.up and stimulus.down (same for all others) in both the figure and table, one number higher in the figure than the Excel for each. degs_matrix_human.xlsx image Is that a bug?

Side note, can't show the set size of the first from the down element, decreasing the size of the text is not working. image

my codes

degs_matrix <- read_excel("degs_matrix_human.xlsx")
degs_matrix <- degs_matrix[1:6]
gene.list <- as.list(degs_matrix)
tiff("UpSet_woPyloric.tiff", width = 13, height = 7, units = "in", res = 600)  # Open the TIFF device
upset(fromList(gene.list), order.by = "freq", nsets = 6, nintersects = NA, text.scale = 2.8,
      set_size.show = T, set_size.numbers_size = 6)
dev.off()

Thanks in advance

Ax3man commented 11 months ago

NAs are being included in the count. If you use lapply(gene.list, na.omit) your set sizes shrink by one.