1

How do you increase the legend font size in UpsetR please?

Here is my code:

library(UpSetR)
library(readr)
data<- read_csv('testData.txt')
Z=as.data.frame(data)

upset(Z, query.legend = "top", text.scale = c(2, 2, 2, 2, 2, 1), sets = c("a", "b", "c", "d","e","f"),
      mainbar.y.label = "Number of hello", sets.x.label = "Total number of hello", sets.bar.color = "grey",
      order.by='freq', keep.order=TRUE, number.angles = 0, point.size = 3, 
      queries = list(
        list(query = intersects,
             params = list("a", "b", "c", "d","e"), 
             color = "skyblue", 
             active = F,
             query.name = "abcde"),
        list(query = intersects,
             params = list("a", "b", "c", "d","e","f"), 
             color = "#Df5286", 
             active = F,
             query.name = "abcdef"),
        list(query = intersects,
             params = list("f"), 
             color = "red", 
             active = F,
             query.name = "f")))
Mohan Singh
  • 1,142
  • 3
  • 15
  • 30

1 Answers1

1

You can use the argument "text.scale", which is a vector that allows you to change: size of intersection size title, intersection size tick labels, set size title, set size tick labels, set names, and numbers above bars. As mentioned in the vignette (https://cran.r-project.org/web/packages/UpSetR/vignettes/basic.usage.html), this is a recent added feature, so you may need to update UpSetR package to use this argument.

lampk
  • 11
  • 1
  • The user is asking about the legend font for `query.name` which is not available through `text.scale` as you mentioned. – Medhat Sep 03 '20 at 20:36