Question: The following correspond to the programming language R. Please write out what the code would be for each category. 1) Use the : or `c()`

The following correspond to the programming language R. Please write out what the code would be for each category.

1) Use the : or `c()` or `seq()` function to create a vector of numbers that ranges from 1 to 10. 2) Name the vector "vector.1" using variable assignment. 3) Print the vector.

---

4) Use the `rep()` function to create a holding vector for a `for()` loop populated with NaN. Make this vector the same length as vector.1 from #1 (a length of 10). 5) Name the vector "vector.2" using variable assignment. 6) Print the vector.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!