Question: Oscar is using R to analyse some data from the sales department at his work. Oscar has created a vector in R that he has

Oscar is using R to analyse some data from the sales department at his work. Oscar has created a vector in R that he has named "staff.sales.revenue", where each element of "staff.sales.revenue" corresponds to the sales revenue from the previous month for a staff member of the sales department. Therefore, the length of the vector "staff.sales.revenue" will equal the number of staff members in the sales department. Oscar has also created a variable in R named "target.value" that is equal to the monthly sales revenue target (a single number) which staff members in the sales department are supposed to meet.

Oscar wants to produce a single value that tells him whether every staff member in the sales department exceeded the target. What code should Oscar enter into R?

Select one:

a.max(staff.sales.revenue>target.value)

b.staff.sales.revenue>target.value

c.all(staff.sales.revenue>target.value)

d.sum(staff.sales.revenue>target.value)

e.any(staff.sales.revenue>target.value)

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 Mathematics Questions!