R-一些小問題

1.The shape palette can deal with a maximum of 6 discrete values because more than 6 becomes difficult to discriminate;.....

解決方法:http://www.sthda.com/english/wiki/ggplot2-point-shapes

總結:ggplot2默認支持六種不同點形,若要增加,如需要七種不同的的點型:

ggplot(data,aes(x=time,y=value))+
  geom_point(aes(shape=school),size=0.8)+
  geom_line()+
  scale_shape_manual(values=c(1,2,4,5,7,8,13))

數字——點型對應如下:

2.

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章