Using R Studio:
1)Use the `mtcars` data (`data(mtcars)`) to answer these questions:
a) Which rows of the data frame contain cars that weigh more than 4000 pounds (the variable is `wt`, units are 1000 pounds).
b) Which cars are these? (*Hint:* since rows are named by car name, use `row.names()`).
c) What is the mean displacement (in inches^3^ ) for cars with at least 200 horsepower (`hp`).
d) Which car has the highest fuel economy (`mpg`)?
e) What was the...
##1a)
*Using the wt column within the mtcars data set, test the
hypothesis that the mean weight is different from 3.00. Use an
alpha level of .01*
```{r}
```
##b
*Comparing different precise recipies for chocolate cake, a study
was conducted to examine the weight in grams of flour in each
recipe. A well known scientific cookbook claims that the true mean
number of grams of flour to put in chocolate cake is 250 grams. A
sample of 8 cake...
Examine classification using logistic regression. In R console,
type mtcars. The dataset mtcars is a generic
dataset in R. This dataset comprises of fuel consumption and 10
aspects of automobile design and performance for 32 automobiles.
Using only the variables am (0 = automatic, 1 = manual)
and mpg, your task is to fit a logistic regression model.
Complete the following steps using R.
Create a scatter plot of am vs. mpg. Describe the relationship
and explain why a simple...
In R, Use library(MASS) to access the data sets for this test.
Use the Pima.tr data set to answer questions 1-5.
What is the average age for women in this data set?
What is the maximum number of pregnancies for women in this data
set ?
What is the median age for women who have diabetes?
What is the median age for women who do not have diabetes?
What is the third quartile of the skin variable?
The data set ”airquality” in the R datasets library has data on
ozone concentration, wind speed, temperature, and solar radiation
by month and day for May through September in New York. Attach
airquality to your workspace and then construct side-by-side
boxplots of Wind by Month. Month is a numeric variable in the
airquality data frame. You can treat it as a factor by using the
”as.factor” function, e.g.,
> plot(Wind ∼ as.factor(Month))
Next, do an analysis of variance to determine...
In R:
Consider dataset “juul” from library “ISwR”. (juul is a built in
data set)
Are the means of igf1 equal among
tanner groups at 5% level?
Please use the six step process to
test statistical hypotheses for this research problem.
Note: You need to convert tanner from
numeric to factor type and ignore all the NAs.
install.packages("mosaic")
library(mosaic)
Data=(RailTrail)
RailTrail
above is the data set it can be found in R
(a) Perform multivariate regression model that can predict the
variable volume based on the variables hightemp, lowtemp,
cloudcover, precip,. Interpret and discuss all the necessary
statics from the output.
(b) Test whether cloudcover can be dropped from the regression
model given that precipitation, hightemp, and lowtemp are retained.
Use the F statistic and level of significance 0.01. State the
hypotheses, p-value, and conclusion in terms...
Please use R to do it.
Using the SATGPA data set in Stat2Data package. Test by using α=
.05
Question: Test if the proportion of MathSAT greater than
VerbalSAT is 0.60
> library(Stat2Data)
> data("SATGPA")
> data(SATGPA)
> SATGPA
R has many build-in dataset. The data mtcars is one of them.
The following R code read-in data and save the data to input.
input <- mtcars[,c("am","cyl","hp","wt")]
Write a few line of R code to conduct a regression analysis with am
as the response variable, and
cyl,
hp, wt as explanation variables.