



Prepara tus exámenes y mejora tus resultados gracias a la gran cantidad de recursos disponibles en Docsity
Gana puntos ayudando a otros estudiantes o consíguelos activando un Plan Premium
Esta página no es visible en la vista previa
¡No te pierdas las partes importantes!




03 of September 2020
and ‘SPEEDING’ the majority of its values are Nan values that we can’t process. Also columns such as ‘SEGLANEKEY’, ‘ CROSSWALKEY’ and ‘HITPARKEDCAR’ had a continue value for almost all of its rows and this tells us that this isn’t a major factor for the outcome of the crash. Once those columns were off the data set, we continued to change the remaining columns names for more easy ones to use. As the remaining columns had the necessary properties for me to analyze them this was all the cleansing I needed to do.
Angles, Parked car and rear ended are the top 3 most common types of accidents in Seattle. All three are common for areas with high traffic which is related with the block areas mentioned above. Also, in block areas people tend to parked their car next to the side walk which would also explained why this type of collision is one of the top three. Finally, we must see what the severity per year of this accidents is to know what type of solution we must give. I chose to create some pie chart showing the percentage of which type of severity (material damage or injury) is most concurrent in this accident:
Machine Learning Model: I decide to make a logistic regression model in which we use the variables: 'Person_count', 'Ice','Oil','Other','Sand/Mud/Dirt','Snow/Slush','Standing Water','Unknown','Wet','Block','Intersection','Cycles', 'Head On','Left Turn', 'Other','Parked Car','Pedestrian','Rear Ended','Right Turn','Sideswipe' and for our ´Y´we chose ´SEVERITYCODE and this were the results. The precision refers to how many of the selected items from the model are relevant and this is calculated by dividing true positives by true positive and false positive. The recall tells how many relevant items were selected and it is calculated by dividing true positives by true positive and false negative. Finally, the f1-score is a measure of accuracy of the model, which is the mean of the model’s precision and recall.
4. Conclusions The model has decent precision values for the 1 and 2 values of 76 and 75 respectively giving us 70%+ relevant values in the model. As for the recall we had 96% and 26% respectively of relevant values selected and finally we had an accuracy score of 0.75 which tells us that this model performs pretty well for this value. Once reviewing all the data the recommendations I may give to the city officials is that they know with this how many of these accidents have occurred in a place where road or light conditions and which type of crash happened in this places and lunch public projects to repair this errors to minimize the results of this factors. As for the car owners they could use this data to take extra precautions certain roads where the light condition, road condition and weather perform badly in order to avoid a severe accident.