HW #1; 20 pts

2 point penalty each day late

Assigned homework should be turned by the end of day listed on Blackboard. Provide your R code and/or figures along with your answer below each exercise. Make sure that your answers are not in bold so that I can easily differentiate between your answer and my question.

Exercise 1

Use R as you would a calculator to find answers to the following (be sure to report R code):

  1. (92-63)*(3/4)
  2. (3+13) / 42

Exercise 2

Show the R code needed to create each of the following vectors. Use the seq function for vec2 and rep function for vec3. (Hint: use the “?rep” function in R to see the documentation and examples for the rep function.)

vec1:     henry       johnson      jackson       clay       bates       nevada

vec2:         5                10               15             20           25             30

vec3:         4                 4                 4               8             8               8

Exercise 3

Use the data.frame command to put the individual vectors from exercise 2 (vec1, vec2, and vec3) into a single data frame named exer3. Report the R code as your answer.

Exercise 4

Rename the column names in exer3 to ‘county’, ‘precip’, and ‘temp’.

Exercise 5

The measurements for the precip column in exer3 are in centimeters. Convert these measurements to millimeters by creating a new column in the exer3 data frame and label it ‘precipmm’. (Hint: values in ‘precipmm’ should be larger than in ‘precip’ by a factor of 10).

All papers are written by ENL (US, UK, AUSTRALIA) writers with vast experience in the field. We perform a quality assessment on all orders before submitting them.

Do you have an urgent order?  We have more than enough writers who will ensure that your order is delivered on time. 

We provide plagiarism reports for all our custom written papers. All papers are written from scratch.

24/7 Customer Support

Contact us anytime, any day, via any means if you need any help. You can use the Live Chat, email, or our provided phone number anytime.

We will not disclose the nature of our services or any information you provide to a third party.

Assignment Help Services
Money-Back Guarantee

Get your money back if your paper is not delivered on time or if your instructions are not followed.

We Guarantee the Best Grades
Assignment Help Services