Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Hi, I am in difficulty when I kept trying to do these R programming questions. Could you give me a help to solve these questions?

Hi, I am in difficulty when I kept trying to do these R programming questions.

Could you give me a help to solve these questions?

Thank you so much.

image text in transcribedimage text in transcribed
\fCreate a vector called countries which contains the names of 5 countries that you would like to visit some day. Print out the elements of the vector. Print out the 4th element of the vector. Create a vector called nums which contains the numbers 6, 7, 8, 9,..., 199, 200 Use the sum() function to add up all of the values in mums. Use the mean() function to nd the average of all of the values in "mums. Create a vector called sleep which contains how many hours of sleep you get on each day of the week (starting with Monday). Create a vector called days which contains the names of the days of the week (starting with Monday). Use the names() function to set the names of the sleep vector to the values of the days vector. Show two different ways to print out the number of hours of sleep you get on a Sunday

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Introductory Algebra

Authors: Alan S Tussy, Rosemary Karr, Marilyn Massey, Diane Koenig, R David Gustafson

5th Edition

1305161866, 9781305161863

More Books

Students also viewed these Mathematics questions

Question

The fear of making a fool of oneself

Answered: 1 week ago

Question

Annoyance about a statement that has been made by somebody

Answered: 1 week ago