Question: Instructions: Write an R script and an R markdown that perform the following operations in the order listed. - - At the beginning of each

Instructions:
Write an R script and an R markdown that perform the following operations in the order listed.
-- At the beginning of each task, write a comment marking the task number. For example
# Task 1
- In the markdown file, include the code for each task in one block.
- Name the files as: lab1-.R and lab1-.Rmd (for markdown)
- After you complete the markdown file, using the knit function to create the HTRM report that contains both the code and the output
Tasks:
1. Learning RStudio environment: examine the 4 panes: source editor, console, workspace browser(objects/variables), and plots. Make sure you understand the purpose and content of each pane. (No script needed for this task)
2. Set the working directory to your Lab1 folder. (No script needed for this task)
3. Create 4 vectors: studentID, firstName, lastName, passFail. Each vector should contain appropriate type of data and at least 5 data elements. Print each vector, check the type and structure of each vector.
4. Create a data frame named studentTable using the 4 vectors that you created in task 3. Print the data frame and check the structure of the data frame.
5. Create 2 matrices. Each matrix should contain at least 20 data elements and at least 3 rows and 3 columns. The two matrices should contain different types of data. Print each matrix. Check the type and structure of each matrix.
6. Create 2 arrays. Each array should contain at least 20 data elements and at least 3 tables. The two arrays should contain different types of data. Print each array. Check the type and structure of each matrix.
7. Create 1 list. The list should have at least 4 vectors. Each vector should have at least 3 data elements. The vectors should have different length and contain at least 2 different types of data. Print the list and check the structure of the list.
8. Create another list containing the list you create in task 7. Print the list.
dsdd

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!