Question: Exercises Write R code to create three vectors (v1, v2, and v3), and initialize them with the following integers. v1: 1, 3, 5 v2: 7,
Exercises
- Write R code to create three vectors (v1, v2, and v3), and initialize them with the following integers.
- v1: 1, 3, 5
- v2: 7, 9, 11
- v3: 13, 15, 17
- Create a matrix using these three vectors where each column represents one of these vectors.
- Create a matrix using these three vectors where each row represents one of these vectors.
- Write R code to create a data frame that contains details of at least seven students and display them as shown below with the same columns of information.

Names Gender student_ID Program Num_Courses 1 Alice Y F F 111111 CET 5 2 Bob z M 222222 CP 4 3 Charlie x M 333333 CST 4 Dian s M 444444 CET 5 ESOS Q F 555555 CP 6 Francois D M 666666 CST NA 7 Garrett E M M 777777 CP 3
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
