官术网_书友最值得收藏!

Variable

Just before digging any deeper, we need to know how to assign values to any variable. So, what is a variable? It's like a container, which holds different value(s) of different types (or the same type). When assigning multiple values to any variable, we write the variable name to the left, followed by an <- or = and then the value. So, if we want to assign 2 to a variable x, we can write either of the two:

x <- 2

or

x = 2
I find the latter convenient, although the R community prefers to use the former – my suggestion is to use one which you find more convenient.

主站蜘蛛池模板: 柳河县| 营山县| 大港区| 绥芬河市| 应用必备| 杨浦区| 淅川县| 尉氏县| 孝感市| 太原市| 内丘县| 黎川县| 永寿县| 五台县| 怀宁县| 池州市| 荔浦县| 和静县| 瑞安市| 镇安县| 望谟县| 堆龙德庆县| 克山县| 贺兰县| 阿坝| 新营市| 措勤县| 肇东市| 襄汾县| 嵊泗县| 肇源县| 稻城县| 嫩江县| 安福县| 岳西县| 平凉市| 邹城市| 海丰县| 沙洋县| 吉木萨尔县| 眉山市|