I'm writing a code to draw upsetR plot, and I have data the same as the example provided by UpsetR package. The first column is factor, and the other is numeric. But the warning message always says that "Must use a vector in
[, not an object of class matrix", I do not know how to deal with it 😷.
In the past, the first column are all character, and I have transferred them into factor, and keep the other columns as numeric.
upset(hh, nsets = 7, nintersects = 30, mb.ratio = c(0.5, 0.5),order.by = c("freq", "degree"), decreasing = c(TRUE,FALSE))
Expected: I just wanna draw an UpsetR plot.
Must use a vector in
[, not an object of class matrix. Call
rlang::last_error()to see a backtrace
but I do not know how and why. And what is the next step to handle with the problems mentioned above. enter image description here