Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

able named theVariable? (The vector above is itself stored in a variable named x

ID: 3049794 • Letter: A

Question

able named theVariable? (The vector above is itself stored in a variable named x) A 5= theVariable BtheVariable=x[5] O-16] = the ariable D theVariable=x16] 3, which command will find the 5% percentile of a dataset that is stored in a vector named theData? A percentile(theData) B quantile(theData,0.05) C fifthPercentile(the Data) D quartile(theData) 4. Which command in R will find the exponential of a number stored in a variable named theExpo? (That is, find ethe Bapo) A etheExpo B exp(theExpo) C exponential(theExpo) D theExpoêxponential 5. Which command in R will find the average of a vector of numbers stored in a variable named theData? A Javerage(theData) B mu(theData) C mean(theData)

Explanation / Answer

3.

Command for 5% percentile is

quantile(theData,0.05)

For example, lets define a vector named "x"

x<-c(2,7,4,9,5,8)

quantile(x,0.05) # this will give 5% percentile

5%

2.5

Answer is B

4.

If the variable name is "theExpo", then its exponential will find out using function "exp"

exp(theExpo)

If,

x<-2

then,

exp(x)

7.389056

Answer is C

5.

The function in R to find average of a vector is "mean"

mean(theData)

If,

x<-c(2,7,4,9,5,8)

mean(x)

5.833333

Answer is C