plot
plot包功能很强大,不同的type出图不同
plot(x2, type = "n", main = "不显示")
plot(x2, type = "p", main = "散点图")
plot(x2, type = "l", main = "折线图")
plot(x2, type = "b", main = "散点+间断折线")
plot(x2, type = "c", main = "间断折线")
plot(x2, type = "o", main = "散点+连续折线")
plot(x2, type = "h", main = "垂直于x轴")
plot(x2, type = "s", main = "楼梯形状")
plot(x2, type = "S", main = "反楼梯形状")
运算
- 算术运算符:基础,+-*/
- 关系运算符:==是否俩相等,!==是否不等于
- 逻辑运算符:based on T/F,和数值无关,所有大于1的数字被认为是逻辑值TRUE。
&:它将第一向量的每个元素与第二向量的相应元素组合,并且如果两个元素都为TRUE,则给出输出TRUE -
赋值运算符