New York Traffic Accidents
Preregistration of analyses
Analysis #1
Question: Do worse weather conditions (e.g. Light Rain vs. Heavy Rain, Light Snow, Heavy Snow, etc.) imply that accidents will be more severe in New York? We want to investigate the relationship between the severity of accidents and weather conditions in New York. Specifically, we are interested in how well the weather conditions on the day of the accident explains or predicts how severe the accident is.
Hypothesis:
\[ H_0: p_{notsevere} - p_{severe} = 0 \]
\[ H_A: p_{notsevere} - p_{severe} \neq 0 \]
Analysis:
- We will first try to conduct inference on our data. We will first fit a model predicting severity (Severity) from weather conditions (Weather_Condition) and display it in a tidy summary output. Use the created model to estimate the severity of an accident if the weather condition of Heavy Snow. We will then write out the estimated model in proper notation and interpret the slope coefficient. Lastly, we will construct a confidence interval by constructing a permuting distribution, creating a 90% confidence interval, and then interpreting the confidence interval in the context of the problem. Lastly, we will run the appropriate hypothesis test, calculate the p-value, and interpret the results in context of the data and the hypothesis test. By conducting these inferences and creating these tests, we will be able to answer our question and derive the answer to whether worse weather conditions can affect the severity of accidents in New York.
Analysis #2
Question:
- Does the time of day have an effect on the severity of the accident if it occurs during the night vs. day in New York? We want to analyze the relationship between at what time of the day accidents occur and the severity of accidents.
Hypothesis:
\(H_0: p_{day} - p_{night} = 0\)
\(H_a: p_{day} - p_{night} \neq 0\)
Analysis
- We will first try to conduct inference on our data. We will first fit a model predicting severity (Severity) from time of day (Sunrise_Sunset) and display it in a tidy summary output. Use the created model to estimate the severity of an accident depending if it is after sunrise (Day) or after sunset (Night). We will then write out the estimated model in proper notation and interpret the slope coefficient. Lastly, we will construct a confidence interval by constructing a permuting distribution, creating a 90% confidence interval, and then interpreting the confidence interval in the context of the problem. Lastly, we will run the appropriate hypothesis test, calculate the p-value, and interpret the results in context of the data and the hypothesis test. This is similar to HW 5 where we were able to analyze, disagree and agree within the same model. By conducting these inferences and creating these tests, we will be able to answer our question.