下面我构建了一个Upset plot。我正在使用颜色调色板来定义条形颜色。有没有办法对连接点的矩阵进行此操作?
library(dplyr)
library(RColorBrewer)
library(UpSetR)
movies <- read.csv(system.file("extdata", "movies.csv",
package = "UpSetR"), header=T, sep=";" )
movies <- select(movies, Action:Children)
upset(movies, main.bar.color=brewer.pal(2^ncol(movies)-1, "Set1"))
当尝试将调色板应用于矩阵时,我会收到警告,并且只使用第一种颜色红色。
upset(movies, main.bar.color=brewer.pal(2^ncol(movies)-1, "Set1"),
matrix.color=brewer.pal(2^ncol(movies)-1, "Set1"))