Answered You can hire a professional tutor to get the answer.

QUESTION

I'm using a chi-square test in R for this question and data set (see below). I typed in the data set verbatim in an excel spreadsheet and then...

I'm using a chi-square test in R for this question and data set (see below). I typed in the data set verbatim in an excel spreadsheet and then imported the sheet into R. I named it "Mood" and used "Social" and "Housing" as my column names.

I used this code:

# Chi-Square using raw data

library(MASS)      # load the MASS package

ProfTable = table(Mood$Social, Mood$Housing)

ProfTable                # the contingency table

chisq.test(ProfTable)

I got this result back:

> library(readxl)> Mood <- read_excel("C:/Users/laure/Desktop/Mood.xlsx"
Show more
Files: Data.png
LEARN MORE EFFECTIVELY AND GET BETTER GRADES!
Ask a Question