R语言画图时,绘图pch参数给定不同值会显示不同的符号,研究者可根据自己需求选取不同的值,
其中每一个值所代表的意义,大家可以参考下面代码和图片了解。
plot(rep(1,10),ylim=c(-2,1.2),pch=1:10,cex=3,axes=F,xlab="",ylab="")
text(rep(0.6,10),as.character(1:10));
points(rep(0,10),pch=11:20,cex=3);
text(rep(-0.4,10),as.character(11:20));
points(rep(-0.8,5),pch=21:25,cex=3);
text(rep(-1.2,5),as.character(21:25));
points(6:10, rep(-0.8,5),pch=c("*","?","X","x","&"),cex=3);
text(6:10,rep(-1.2,5),c("*","?","X","x","&"));
|