Quiz 2
STA4102, SEC 001, SPRING15
Instructor: Doo-Young Kim
Last Name:
First Name:
1. Open a new R-script file and save it as LastName_Q1.R.
2. Choose only 2 problems among 3, and Answer to the problems you selected.
3. Email to sta4102.usf@gmail.com with
# Sol 1
x <- c()
for (k in 1:1000)cfw_
u <- runif(1)
x[k] <- u*(1/3)
print(x)
mean(x)
f <- function(x) 3*x*3
theoreticalmean <- integrate(f,0,1); theoreticalmean
# Sol 2
a <- 1:10
b <-c()
for(i in 1:length(a) cfw_
if(a[i]%2=0) b[i] <- "even"
else b[i
Quiz 5
STA4102, SEC 001, SPRING15
Last Name:
Instructor: Doo-Young Kim
First Name:
1. Open a new editor file and save it as LastName_Q5.sas.
2. Answer to the problems below.
3. Email to sta4102.usf@gmail.com with the saved SAS editor file as an attachment
Quiz 3
STA4102, SEC 001, SPRING15
Last Name:
Instructor: Doo-Young Kim
First Name:
1. Open a new editor file and save it as LastName_Q3.sas.
2. Answer to the problems below.
3. Email to sta4102.usf@gmail.com with the saved SAS editor file as an attachment
Quiz 1
STA4102, SEC 001, SPRING15
Last Name:
Instructor: Doo-Young Kim
First Name:
1. Open a new R-script file and save it as LastName_Q1.R.
2. Answer to the problems below.
3. Email to sta4102.usf@gmail.com with the saved R-script file as an attachment.