Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

data(ChickWeight) # Create T | F vector indicating observations with Diet == 3 index

data(ChickWeight)

# Create T | F vector indicating observations with Diet == "3"

index <- ChickWeight$Diet == "3"

# Create vector of "weight" for observations where Diet == "3" and Time == 20

pre <- subset(ChickWeight[index, ], Time == 20, select = weight)$weight

pre

# Create vector of "weight" for observations where Diet == "3" and Time == 21

post <- subset(ChickWeight[index, ], Time == 21, select = weight)$weight

post

# The pre and post values are paired, each pair corresponding to an individual chick.

cbind(pre, post)

Perform a one-sided, paired t-test on the Time == 20 and Time == 21 paired data.

provide t_stat," "p_value," "crit_t" and "lower_ci."

You are to 'manually' implement the test, rather than use t.test(), but you can use t.test() to confirm your work.

our "alternative" hypothesis is weight gain from day 20 to 21, that we are using paired data,

#and that our confidence interval will extend to positive infinity.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Elementary Differential Equations And Boundary Value Problems

Authors: William E Boyce, Richard C DiPrima

10th Edition

1118475739, 9781118475737

More Books

Students also viewed these Mathematics questions

Question

Do you feel you did the best scholastic work you are capable of?

Answered: 1 week ago

Question

=+a) Why is there no coefficient for Medium?

Answered: 1 week ago

Question

1. To understand how to set goals in a communication process

Answered: 1 week ago