# Utilizing Different Machine Learning Techniques to Examine Speeding Violations
## 2 Materials and Methods
\begin{table}
\begin{tabular}{c c c c c c c c} \hline \hline
**Variable** & **Category** & **Count** & **Percent** & **Variable** & **Category** & **Count** & **Percent** \\ \hline \multirow{2}{*}{**Speeding Violation**} & Yes & 8175 & 16.0 & \multirow{2}{*}{**Gender**} & Female & 14,275 & 27.9 \\  & No & 42,961 & 84.0 & & Male & 36,861 & 72.1 \\ \hline \multirow{3}{*}{**Traffic Way**} & One way & 771 & 1.5 & \multirow{3}{*}{**Road Grade**} & Level & 45,181 & 88.4 \\  & Two way & 50,365 & 98.5 & & Ascending & 3214 & 6.3 \\  & - & - & - & & Descending & 2741 & 5.4 \\ \hline \multirow{3}{*}{**Holiday**} & Yes & 1446 & 2.80 & \multirow{3}{*}{**Area Type**} & Rural & 20,820 & 40.7 \\  & No & 49,690 & 97.20 & & Urban & 30,316 & 59.3 \\ \hline \multirow{2}{*}{**Day of The Week**} & Weekend & 16,539 & 32.30 & \multirow{2}{*}{**Work Zone**} & Yes & 1600 & 3.1 \\  & Weekday & 34,597 & 67.70 & & No & 49,536 & 96.9 \\ \hline \multirow{2}{*}{**Road Alignment**} & Straight & 42,491 & 83.1 & \multirow{2}{*}{**Traffic Control**} & Yes & 8518 & 16.7 \\  & Curve & 8645 & 16.9 & & No & 42,618 & 83.3 \\ \hline \multirow{3}{*}{**Accident Year**} & 2015 & 12,716 & 24.9 & \multirow{3}{*}{**Road Surface**} & Dry & 44,387 & 86.8 \\  & 2016 & 12,043 & 23.6 & & Wet & 6223 & 12.2 \\  & 2017 & 7112 & 13.9 & & Snow & 366 & 0.7 \\  & 2018 & 10,658 & 20.8 & & **Condition** & Mud & 98 & 0.2 \\  & 2019 & 8607 & 16.8 & & slush & 62 & 0.1 \\ \hline \multirow{3}{*}{**License Type**} & Full & 50,003 & 97.8 & \multirow{3}{*}{**Season**} & Spring & 12,984 & 25.4 \\  & Intermediate & 759 & 1.5 & & Summer & 13,090 & 25.6 \\  & Learner & 333 & 0.7 & & Autumn & 13,335 & 26.1 \\  & Temporary & 41 & 0.1 & & Winter & 11,727 & 22.9 \\ \hline \multirow{3}{*}{**Accident Time**} & 0:00–6:59 & 11,275 & 22.0 & \multirow{3}{*}{**Age**} & \(\leq\)25 & 11,004 & 21.5 \\  & 7:00–8:59 & 3350 & 6.6 & & 26–35 & 10,503 & 20.5 \\  & 9:00–11:59 & 5060 & 9.9 & & 36–45 & 8127 & 15.9 \\  & 12:00–16:59 & 12,470 & 24.4 & & 46–55 & 8068 & 15.8 \\  & 17:00–19:59 & 8870 & 17.3 & & 56–65 & 6570 & 12.8 \\  & 20:00–23:59 & 10,111 & 19.8 & & \(\geq\)66 & 6864 & 13.4 \\ \hline \multirow{3}{*}{**Light Condition**} & Daylight & 25,703 & 50.3 & \multirow{3}{*}{**Weather**} & Clear & 38,219 & 74.7 \\  & Dusk & 1361 & 2.7 & & Rain & 3617 & 7.1 \\  & Dawn & 986 & 1.9 & & Cloudy & 8144 & 15.9 \\  & Dark not lightted & 13,590 & 26.6 & & Fog & 661 & 1.3 \\  & Dark lightted & 9496 & 18.6 & & Snow & 334 & 0.7 \\  & & & & Other & 161 & 0.3 \\ \hline \multirow{3}{*}{**Number of Lanes**} & One & 27,828 & 54.4 & \multirow{3}{*}{**Weather**} & \(\leq\)30 & 287 & 0.6 \\  & Two & 9333 & 18.3 & & 30–40 & 645 & 1.3 \\  & Three & 6836 & 13.4 & & 40–50 & 3884 & 7.6 \\  & Four & 4511 & 8.8 & & 50–60 & 5468 & 10.7 \\  & Five & 1611 & 3.2 & **Speed Limit** & 60–70 & 3667 & 7.2 \\  & Six & 881 & 1.7 & **(km/h)** & 70–80 & 9520 & 18.6 \\  & Seven or more & 136 & 0.3 & & 80–90 & 14,665 & 28.7 \\  & - & - & - & & 90–100 & 2485 & 4.9 \\  & - & - & - & & 100–110 & 4664 & 9.1 \\  & - & - & - & & \(>\)110 & 5851 & 11.4 \\ \hline \multirow{3}{*}{**Vehicle model year**} & Before 1991 & 1116 & 2.2 & \multirow{3}{*}{**Weather**} & \multirow{3}{*}{**Weather**} & \multirow{3}{*}{**Weather**} \\  & 1991–2000 & 8941 & 17.5 & & & \\ \cline{1-1}  & 2000–2010 & 23,878 & 46.7 & & & \\ \cline{1-1}  & 2010–2020 & 17,201 & 33.6 & & & \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Variables Description for the Studied Data. tion [32]. The impurity function is a splitting criterion used to specify the suitable variable that gives the best subset at the splitting point. Entropy, Gini index, and minimum error are examples of impurity functions aiming to select the split that gives the most significant difference between the parent node's impurity and the impurity of the weighted average of the child nodes [33]. In order to produce a tree of an appropriate size and improve model predictions, a pruning process is conducted after the training phase to remove any unimportant branches [32].