Generation

generate functionTue, 14 Mar 2023

John is looking to invest in the Canadian Stock Market. In particular, John wants to maximize his received cash flows, so he would like to invest in companies that have a high dividend per share ratio. Load the FinanceCanada.csv dataset. This contains randomly chosen Canadian companies sorted into seven industry groups (1=real estate, 2=financial, etc), along with a variety of financial metrics. To direct his investing, John would like to test whether certain types of industries have on average a higher dividend per share ratio. a) State the null and alternative hypotheses

industry <- read.csv("FinanceCanada.csv") industry1 <- subset(industry, Industry == 1) industry2 <- subset(industry, Industry == 2) industry3 <- subset(industry, Industry == 3) industry4 <- subset(industry, Industry == 4) industry5 <- subset(industry, Industry == 5) industry6 <- subset(industry, Industry == 6) industry7 <- subset(industry, Industry == 7) # Null hypothesis: What is the average dividend per share ratio of the entire population? # Alternative hypothesis: The average dividend per share ratio of industry 1 is different than the population's. # The alternative hypothesis is the same for all industries # The null hypothesis is that the mean is equal to 0 # The alternative hypothesis is that the mean is not equal to 0 # The alternative hypothesis is that the mean is greater than 0 # The alternative hypothesis is that the mean is less than 0 # The alternative hypothesis is that the mean is not equal to the population's mean # Null hypothesis: What is

Questions about programming?Chat with your personal AI assistant