This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Dotplot error: subscript out of bound

Hi everyone,

How to solve the problem when I

DotPlot(seuratobject, features =  c("ACTA2"), dot.scale = 8) + 
  coord_flip() + 
  theme_bw() +
  theme(panel.grid = element_blank(), axis.text.x=element_text(angle=90,hjust = 1,vjust=1)) +
  scale_colour_gradientn(values = seq(0,1,0.2), colours = c('#330066','#336699','#66CC66','#FFCC33')) +
  labs(x=NULL,y=NULL) +
  guides(size=guide_legend(order=3)) +
  RotatedAxis()

The problem is likely caused by the fact that there are multiple groups (four group) under "orig.ident".

Thank you tons.

r scrna-seq seurat

Did you try to remove scale_colour_gradientn? You are passing 6 values and only specifying 4 colours

Got it. Thanks a lot.

0 answers

No answers yet.

Log in to answer this question.