Traffic data provides a valuable insight into the livelihoods of a community. By determining associations between events and the volume of traffic, more informed decisions/statements regarding lead-times/delivery-times, impacts of large-scale events and more, can be made. By collecting data using E-tags from the Cross-City Tunnel in Sydney, it has been found that:
Fridays are the busiest day of the week (largest traffic volume), surpassing 15% of the total traffic proportion during the week.
There is an association between the COVID restrictions enforced during March 2020, and the reduction in traffic by an estimated 3482 vehicles each day.
The reports dataset “traffic”, sourced from NSW Toll Road Data (RSM-Transurban), uses toll collection points to track vehicle volume/type along the cross-city tunnel (CCT) and records them in a series of 15 min intervals 24/7 during the months of March-2019 and March-2020.
Transurban data for the CCT uses nationally recognised/compulsory E-tags (since 2009) for all drivers to use, when on toll roads. E-Tags work via radio-frequency-identification-Transponders (RFID) with a dedicated short-range communications (DSRC) system. Overhead Gantries on motorways then have the purpose of recording registration plates and detecting/linking the E-Tags. Using this system of vehicle-tracking, is an effective and reliable way of determining trends in roadway traffic (Amsler & Shea, n.d.).
As the data collection method is digitised, the bias is significantly reduced, however, there will be selection bias as certain groups may choose to avoid toll roads in order to save costs on travelling. Another limitation of accuracy in the dataset could be observed by circumstances where cars have either no/multiple E-Tags present. In 2020 this was addressed/improved by Transurban, enabling faster removal of duplicate tags (Global Notes – NSW Toll Road Data). The instances of no E-tags in a vehicle is minimised by awarding infringement penalties up to $190.
## Reading the code and skipping a row in the data to get the true headers
traffic= read.csv("data/traffic.csv", header = T, skip = 1)
## Converting date column into Dates read by R.
Date=traffic$Date
date=as.Date(Date)
class(date)
## [1] "Date"
## Adding weekdays to the dataset variables.
traffic$weekday=weekdays(date)
## Re-ordering dataset columns by index, to make weekdays after date. And only keeping the Variables of use for simplicity.
Traffic=traffic[ ,c(3,15,4,5,7,10,14)]
head(Traffic)
## Date weekday IntervalStart IntervalEnd VehicleClass GantryLocation
## 1 2019-03-01 Friday 00:00 00:14 Car Mainline Eastbound
## 2 2019-03-01 Friday 00:00 00:14 Truck Mainline Eastbound
## 3 2019-03-01 Friday 00:00 00:14 Car Sir John Young
## 4 2019-03-01 Friday 00:00 00:14 Truck Sir John Young
## 5 2019-03-01 Friday 00:00 00:14 Car Mainline Westbound
## 6 2019-03-01 Friday 00:00 00:14 Truck Mainline Westbound
## TotalVolume
## 1 23
## 2 2
## 3 10
## 4 0
## 5 18
## 6 2
## Identifying types of variables in dataset.
str(Traffic)
## 'data.frame': 35712 obs. of 7 variables:
## $ Date : chr "2019-03-01" "2019-03-01" "2019-03-01" "2019-03-01" ...
## $ weekday : chr "Friday" "Friday" "Friday" "Friday" ...
## $ IntervalStart : chr "00:00" "00:00" "00:00" "00:00" ...
## $ IntervalEnd : chr "00:14" "00:14" "00:14" "00:14" ...
## $ VehicleClass : chr "Car" "Truck" "Car" "Truck" ...
## $ GantryLocation: chr "Mainline Eastbound" "Mainline Eastbound" "Sir John Young" "Sir John Young" ...
## $ TotalVolume : int 23 2 10 0 18 2 21 1 6 0 ...
date: Refers to the date at which the data interval was recorded. This has been converted from an ordinal qualitative variable to be classed as a date in R.
Weekday: The weekday of vehicle travel has been coded into the original dataset and read as a qualitative ordinal variable.
IntervalStart/IntervalEnd: Refers to the interval start and end times respectively, notated in 24 hr time. Read as a qualitative ordinal variable.
VehicleClass: Refers to the vehicle as being a car or truck. Read as a qualitative nominal variable.
GantryLocation: Refers to the toll-road used in the CCT (Mainline Eastbound, Mainline Westbound, Sir John Young). Read as a qualitative nominal variable.
TotalVolume: Total number of vehicles which passed through the toll points during the 15 min interval. Read as a quantitative variable (integer) in the dataset.
## Splitting the dataset into periods of traffic for March 2019 and March 2020. This makes Data more targeted and reliable for use in each of the research questions.
Traffic_March_2019=Traffic[1:17856, ]
Traffic_March_2020=Traffic[17857:35712, ]
head(Traffic_March_2019)
## Date weekday IntervalStart IntervalEnd VehicleClass GantryLocation
## 1 2019-03-01 Friday 00:00 00:14 Car Mainline Eastbound
## 2 2019-03-01 Friday 00:00 00:14 Truck Mainline Eastbound
## 3 2019-03-01 Friday 00:00 00:14 Car Sir John Young
## 4 2019-03-01 Friday 00:00 00:14 Truck Sir John Young
## 5 2019-03-01 Friday 00:00 00:14 Car Mainline Westbound
## 6 2019-03-01 Friday 00:00 00:14 Truck Mainline Westbound
## TotalVolume
## 1 23
## 2 2
## 3 10
## 4 0
## 5 18
## 6 2
head(Traffic_March_2020)
## Date weekday IntervalStart IntervalEnd VehicleClass
## 17857 2020-03-01 Sunday 00:00 00:14 Car
## 17858 2020-03-01 Sunday 00:00 00:14 Truck
## 17859 2020-03-01 Sunday 00:00 00:14 Car
## 17860 2020-03-01 Sunday 00:00 00:14 Truck
## 17861 2020-03-01 Sunday 00:00 00:14 Car
## 17862 2020-03-01 Sunday 00:00 00:14 Truck
## GantryLocation TotalVolume
## 17857 Mainline Eastbound 177
## 17858 Mainline Eastbound 1
## 17859 Sir John Young 55
## 17860 Sir John Young 0
## 17861 Mainline Westbound 157
## 17862 Mainline Westbound 0
The CCT is a very popular roadway in Sydney and can provide useful insight towards traffic trends within Sydney city. As traffic data is to become more reliable (e.g. transportation routes for emergency services), the significance level for the hypothesis testing is reduced to 0.01 meaning the confidence interval is 99%. Friday is hypothesised to have the greatest traffic volume as it is the day (for most) of transitioning from the work week into the weekend, meaning there is still work and school to attend but during the night there is often commute for weekend get-aways and social events.
## By modifying the Traffic in March 2019 to only represent volume of vehicles per day during March 2019, it gives a more concise and practical representation of the dataset.
fri_1= Traffic_March_2019[1:576,]
FRI_1=sum(fri_1$TotalVolume)
sat_2= Traffic_March_2019[577:1152,]
SAT_2=sum(sat_2$TotalVolume)
sun_3= Traffic_March_2019[1153:1728,]
SUN_3=sum(sun_3$TotalVolume)
mon_4= Traffic_March_2019[1729:2304,]
MON_4=sum(mon_4$TotalVolume)
tue_5= Traffic_March_2019[2305:2880,]
TUE_5=sum(tue_5$TotalVolume)
wed_6= Traffic_March_2019[2881:3456,]
WED_6=sum(wed_6$TotalVolume)
thu_7= Traffic_March_2019[3457:4032,]
THU_7=sum(thu_7$TotalVolume)
fri_8= Traffic_March_2019[4033:4608,]
FRI_8=sum(fri_8$TotalVolume)
sat_9= Traffic_March_2019[4609:5184,]
SAT_9=sum(sat_9$TotalVolume)
sun_10= Traffic_March_2019[5185:5760,]
SUN_10=sum(sun_10$TotalVolume)
mon_11= Traffic_March_2019[5761:6336,]
MON_11=sum(mon_11$TotalVolume)
tue_12= Traffic_March_2019[6337:6912,]
TUE_12=sum(tue_12$TotalVolume)
wed_13= Traffic_March_2019[6913:7488,]
WED_13=sum(wed_13$TotalVolume)
thu_14= Traffic_March_2019[7489:8064,]
THU_14=sum(thu_14$TotalVolume)
fri_15= Traffic_March_2019[8065:8640,]
FRI_15=sum(fri_15$TotalVolume)
sat_16= Traffic_March_2019[8641:9216,]
SAT_16=sum(sat_16$TotalVolume)
sun_17= Traffic_March_2019[9217:9792,]
SUN_17=sum(sun_17$TotalVolume)
mon_18= Traffic_March_2019[9793:10368,]
MON_18=sum(mon_18$TotalVolume)
tue_19= Traffic_March_2019[10369:10944,]
TUE_19=sum(tue_19$TotalVolume)
wed_20= Traffic_March_2019[10945:11520,]
WED_20=sum(wed_20$TotalVolume)
thu_21= Traffic_March_2019[11521:12096,]
THU_21=sum(thu_21$TotalVolume)
fri_22= Traffic_March_2019[12097:12672,]
FRI_22=sum(fri_22$TotalVolume)
sat_23= Traffic_March_2019[12673:13248,]
SAT_23=sum(sat_23$TotalVolume)
sun_24= Traffic_March_2019[13249:13824,]
SUN_24=sum(sun_24$TotalVolume)
mon_25= Traffic_March_2019[13825:14400,]
MON_25=sum(mon_25$TotalVolume)
tue_26= Traffic_March_2019[14401:14976,]
TUE_26=sum(tue_26$TotalVolume)
wed_27= Traffic_March_2019[14977:15552,]
WED_27=sum(wed_27$TotalVolume)
thu_28= Traffic_March_2019[15553:16128,]
THU_28=sum(thu_28$TotalVolume)
fri_29= Traffic_March_2019[16129:16704,]
FRI_29=sum(fri_29$TotalVolume)
sat_30= Traffic_March_2019[16705:17280,]
SAT_30=sum(sat_30$TotalVolume)
sun_31= Traffic_March_2019[17281:17856,]
SUN_31=sum(sun_31$TotalVolume)
## Creating values for the TotalVolume of traffic for each weekday in March 2019
## Need to download and use the group_by function which belongs to "dplyr".
# install.packages("dplyr")
library("dplyr")
##
## Attaching package: 'dplyr'
## The following objects are masked from 'package:stats':
##
## filter, lag
## The following objects are masked from 'package:base':
##
## intersect, setdiff, setequal, union
## Saving the summary volume data for each weekday.
March2019WeekdayVolume= Traffic_March_2019 %>% group_by(weekday) %>%
summarise(Volume = sum(TotalVolume))
March2019WeekdayVolume
## # A tibble: 7 × 2
## weekday Volume
## <chr> <int>
## 1 Friday 237998
## 2 Monday 159089
## 3 Saturday 209192
## 4 Sunday 160749
## 5 Thursday 181831
## 6 Tuesday 173115
## 7 Wednesday 178161
## Assigning known total values of the month in March 2019. (This is derived from March2019WeekdayVolume)
Mon_Total_2019= 159089
Tue_Total_2019= 173115
Wed_Total_2019= 178161
Thu_Total_2019= 181831
Fri_Total_2019= 237998
Sat_Total_2019= 209192
Sun_Total_2019= 160749
## As there are 4 days in the month of March 2019 for Mon-Thu and 5 days for Fri-Sun. Take the average daily volume and use this as a fair comparison for the average volume of traffic per day during the week.
Mon_Avg_2019= 159089/4
Tue_Avg_2019= 173115/4
Wed_Avg_2019= 178161/4
Thu_Avg_2019= 181831/4
Fri_Avg_2019= 237998/5
Sat_Avg_2019= 209192/5
Sun_Avg_2019= 160749/5
# Finding the average volume of cars per day during March 2019}
Volume_2019=sum(Traffic_March_2019$TotalVolume)
AVG_2019=Volume_2019/31
c(AVG_2019, Volume_2019)
## [1] 41939.84 1300135.00
## Creating a dataset using only the daily Volume and date/day at which the vehicles were tracked.
NEW_March_2019= data.frame(DATE= c("FRI1","SAT2", "SUN3", "MON4", "TUE5", "WED6", "THU7", "FRI8", "SAT9", "SUN10", "MON11", "TUE12", "WED13", "THU14", "FRI15", "SAT16", "SUN17", "MON18", "TUE19", "WED20", "THU21", "FRI22", "SAT23", "SUN24", "MON25", "TUE26", "WED27", "THU28", "FRI29", "SAT30", "SUN31"),
VOLUME_DAY_2019= c(FRI_1,SAT_2, SUN_3, MON_4, TUE_5, WED_6, THU_7, FRI_8, SAT_9, SUN_10, MON_11, TUE_12, WED_13, THU_14, FRI_15, SAT_16, SUN_17, MON_18, TUE_19, WED_20, THU_21, FRI_22, SAT_23, SUN_24, MON_25, TUE_26, WED_27, THU_28, FRI_29, SAT_30, SUN_31) )
## With a large sample size and an unknown population standard deviation, it is appropriate to apply the z-test in order to quantify the accuracy or confidence level of the hypothesis presented
Friday has the largest volume of traffic with proportion of traffic greater then 15% of the entire traffic during the week (which is greater than the proportion of traffic then if it were to spread equally among the days of the week – 1/7=14.29%).
Null-Hypothesis (H0): P=0.15
Alternative-Hypothesis (H1): P<0.15
## Finding the Standard deviation and Mean of the data (volume of vehicles in days of March 2019)
SD=sd(NEW_March_2019$VOLUME_DAY_2019)
MU=(0.15*sum(NEW_March_2019$VOLUME_DAY_2019))/5
c(SD,MU)
## [1] 5233.957 39004.050
## Deriving key values to find the z-value. This includes using the sample size (31 days), the observed value, the expected value and the standard error.
n=31
OV_SUM=Fri_Avg_2019
EV_SUM=MU
SE_SUM=SD/sqrt(n)
c(OV_SUM, EV_SUM, SE_SUM)
## [1] 47599.6000 39004.0500 940.0464
## Computing the Z-value;
Z=(OV_SUM-EV_SUM)/(SE_SUM)
Z
## [1] 9.143751
Thus the Test-statistic (Z-Value) is 9.14
## Computing the P-value associated with obtaining the null hypothesis result with the given sample data;
P=pnorm(Z,0,1,lower.tail=F)
P
## [1] 3.016147e-20
The derived probability of obtaining a proportion of 0.15 is P= 0.0003942 or 0.039%.
As this is well-below the significance level (0.01), the null hypothesis can be firmly rejected and have a confidence in the alternative hypothesis of 99% certainty. This means there is a 99% likelihood that the traffic on Fridays are greater than 0.15 proportion.This can then be interpreted for uses like ambulance drivers in providing more accurate lead times to patients using the weekday as a variable in traffic conditions.
## Creating a dataframe to effectively barplot the average volume of traffic per day of the week during March 2019
BPLOT_Volume_Weekday_2019= data.frame(Day= c((rep("(a) Monday",Mon_Avg_2019)), ((rep("(b) Tuesday",Tue_Avg_2019))), (rep("(c) Wednesday",Wed_Avg_2019)), (rep("(d) Thursday",Thu_Avg_2019)), (rep("(e) Friday",Fri_Avg_2019)), (rep("(f) Saturday",Sat_Avg_2019)), (rep("(g) Sunday",Sun_Avg_2019))), Vehicle_Volume=rep(1, 294633))
barplot(table(BPLOT_Volume_Weekday_2019$Vehicle_Volume, BPLOT_Volume_Weekday_2019$Day), main="Volume of traffic Per day of the week in total across March 2019", xlab="Day of the week", ylab="Total Volume", ylim=c(0, 50000), las=2)
abline(h=AVG_2019, col="red")
The COVID Pandemic had an enormous impact across the globe due to dramatic loss of human life and led to an economic downswing in an attempt to control/prevent the spread. The impact was also substantial for Sydney, particularly during Early-Mid 2020, whereabouts Restrictions and Lockdowns began to be enforced. This disturbance to the typical livelihood of Sydney residents can be quantified by analysing the traffic difference between the impacted period (March 2020) and a control period (March 2019). According to Duckett and Stobart (2020), the timeline of COVID restrictions during March 2020:
- 1st to 14th March: No restrictions (P1)
- 15th to 17th March: Social gatherings limited to 500 people (P2)
- 18th to 19th March: Social gatherings limited to 100 people (P3)
- 20th to 22nd March: Australia’s borders close internationally (P4)
- 23rd to 24th March: Stage 1 shutdown (P5)
- 25th to 28th March: Stage 2 shutdown (P6)
- 29th to 31st March: Stage 3 shutdown (P7)
Entire details of what is included in each of these restriction phases can be clarified from Gadiel (2020) and similarly from Storen and Corrigan (2020).
## Creating new dataset for only days in March 2020 to simplify the calculations
sun_1= Traffic_March_2020[1:576,]
SUN_1=sum(sun_1$TotalVolume)
mon_2= Traffic_March_2020[577:1152,]
MON_2=sum(mon_2$TotalVolume)
tue_3= Traffic_March_2020[1153:1728,]
TUE_3=sum(tue_3$TotalVolume)
wed_4= Traffic_March_2020[1729:2304,]
WED_4=sum(wed_4$TotalVolume)
thu_5= Traffic_March_2020[2305:2880,]
THU_5=sum(thu_5$TotalVolume)
fri_6= Traffic_March_2020[2881:3456,]
FRI_6=sum(fri_6$TotalVolume)
sat_7= Traffic_March_2020[3457:4032,]
SAT_7=sum(sat_7$TotalVolume)
sun_8= Traffic_March_2020[4033:4608,]
SUN_8=sum(sun_8$TotalVolume)
mon_9= Traffic_March_2020[4609:5184,]
MON_9=sum(mon_9$TotalVolume)
tue_10= Traffic_March_2020[5185:5760,]
TUE_10=sum(tue_10$TotalVolume)
wed_11= Traffic_March_2020[5761:6336,]
WED_11=sum(wed_11$TotalVolume)
thu_12= Traffic_March_2020[6337:6912,]
THU_12=sum(thu_12$TotalVolume)
fri_13= Traffic_March_2020[6913:7488,]
FRI_13=sum(fri_13$TotalVolume)
sat_14= Traffic_March_2020[7489:8064,]
SAT_14=sum(sat_14$TotalVolume)
sun_15= Traffic_March_2020[8065:8640,]
SUN_15=sum(sun_15$TotalVolume)
mon_16= Traffic_March_2020[8641:9216,]
MON_16=sum(mon_16$TotalVolume)
tue_17= Traffic_March_2020[9217:9792,]
TUE_17=sum(tue_17$TotalVolume)
wed_18= Traffic_March_2020[9793:10368,]
WED_18=sum(wed_18$TotalVolume)
thu_19= Traffic_March_2020[10369:10944,]
THU_19=sum(thu_19$TotalVolume)
fri_20= Traffic_March_2020[10945:11520,]
FRI_20=sum(fri_20$TotalVolume)
sat_21= Traffic_March_2020[11521:12096,]
SAT_21=sum(sat_21$TotalVolume)
sun_22= Traffic_March_2020[12097:12672,]
SUN_22=sum(sun_22$TotalVolume)
mon_23= Traffic_March_2020[12673:13248,]
MON_23=sum(mon_23$TotalVolume)
tue_24= Traffic_March_2020[13249:13824,]
TUE_24=sum(tue_24$TotalVolume)
wed_25= Traffic_March_2020[13825:14400,]
WED_25=sum(wed_25$TotalVolume)
thu_26= Traffic_March_2020[14401:14976,]
THU_26=sum(thu_26$TotalVolume)
fri_27= Traffic_March_2020[14977:15552,]
FRI_27=sum(fri_27$TotalVolume)
sat_28= Traffic_March_2020[15553:16128,]
SAT_28=sum(sat_28$TotalVolume)
sun_29= Traffic_March_2020[16129:16704,]
SUN_29=sum(sun_29$TotalVolume)
mon_30= Traffic_March_2020[16705:17280,]
MON_30=sum(mon_30$TotalVolume)
tue_31= Traffic_March_2020[17281:17856,]
TUE_31=sum(tue_31$TotalVolume)
NEW_March_2020= data.frame(DATE= c("SUN1","MON2", "TUE3", "WED4", "THU5", "FRI6", "SAT7", "SUN8", "MON9", "TUE10", "WED11", "THU12", "FRI13", "SAT14", "SUN15", "MON16", "TUE17", "WED18", "THU19", "FRI20", "SAT21", "SUN22", "MON23", "TUE24", "WED25", "THU26", "FRI27", "SAT28", "SUN29", "MON30", "TUE31"),
VOLUME_DAY_2020= c(SUN_1,MON_2, TUE_3, WED_4, THU_5, FRI_6, SAT_7, SUN_8, MON_9, TUE_10, WED_11, THU_12, FRI_13, SAT_14, SUN_15, MON_16, TUE_17, WED_18, THU_19, FRI_20, SAT_21, SUN_22, MON_23, TUE_24, WED_25, THU_26, FRI_27, SAT_28, SUN_29, MON_30, TUE_31))
library("dplyr")
## Saving the summary volume data for each weekday.
March2020WeekdayVolume= Traffic_March_2020 %>% group_by(weekday) %>%
summarise(Volume = sum(TotalVolume))
March2020WeekdayVolume
## # A tibble: 7 × 2
## weekday Volume
## <chr> <int>
## 1 Friday 161457
## 2 Monday 171523
## 3 Saturday 120443
## 4 Sunday 124366
## 5 Thursday 155574
## 6 Tuesday 174311
## 7 Wednesday 153810
## Assigning known total values of the month in March 2020 (derived from March2020WeekdayVolume)
Mon_Total_2020= 171523
Tue_Total_2020= 174311
Wed_Total_2020= 153810
Thu_Total_2020= 155574
Fri_Total_2020= 161457
Sat_Total_2020= 120443
Sun_Total_2020= 124366
## As there are 5 days in the month of March 2020 for Sun,Mon,Tue and 4 days for Wed-Sat. Take the average daily volume and use this as a fair comparison.
Mon_Avg_2020= 171523/5
Tue_Avg_2020= 174311/5
Wed_Avg_2020= 153810/4
Thu_Avg_2020= 155574/4
Fri_Avg_2020= 161457/4
Sat_Avg_2020= 120443/4
Sun_Avg_2020= 124366/5
# For P1:
## Determining the average volume per day in P1 of March 2020
AVG_P1_20= mean(NEW_March_2020$VOLUME_DAY_2020[1:14])
## As P1 is spread evenly across all days in a 2 week period. Use the average of all days in 2019 as a comparison.
AVG_P1_19= AVG_2019
# For P2:
## Determining the average volume per day in P2 of March 2020
AVG_P2_20= mean(NEW_March_2020$VOLUME_DAY_2020[15:17])
## As P2 is spread across Sunday, Monday and Tuesday. Use the average of the 3 days from 2019 as a comparison.
AVG_P2_19= (Sun_Avg_2019 + Mon_Avg_2019 + Tue_Avg_2019)/3
# For P3:
## Determining the average volume per day in P3 of March 2020
AVG_P3_20= mean(NEW_March_2020$VOLUME_DAY_2020[18:19])
## As P3 is spread across Monday and Tuesday. Use the average of both days in 2019 as a comparison.
AVG_P3_19= (Wed_Avg_2019 + Thu_Avg_2019)/2
# For P4:
## Determining the average volume per day in P4 of March 2020
AVG_P4_20= mean(NEW_March_2020$VOLUME_DAY_2020[20:22])
## As P4 is spread across Friday, Saturday and Sunday. Use the average of the 3 days in 2019 as a comparison.
AVG_P4_19= (Fri_Avg_2019 + Sat_Avg_2019 + Sun_Avg_2019)/3
# For P5:
## Determining the average volume per day in P5 of March 2020
AVG_P5_20= mean(NEW_March_2020$VOLUME_DAY_2020[23:24])
## As P5 is spread evenly across a Monday and Tuesday. Use the average of both days in 2019 as a comparison.
AVG_P5_19= (Mon_Avg_2019 + Tue_Avg_2019)/2
# For P6:
## Determining the average volume per day in P6 of March 2020
AVG_P6_20= mean(NEW_March_2020$VOLUME_DAY_2020[25:28])
## As P6 is spread across a Wednesday, Thursday, Friday and Saturday. Use the average of these 4 days in 2019 as a comparison.
AVG_P6_19= (Wed_Avg_2019 + Thu_Avg_2019 + Fri_Avg_2019 + Sat_Avg_2019)/4
# For P7:
## Determining the average volume per day in P7 of March 2020
AVG_P7_20= mean(NEW_March_2020$VOLUME_DAY_2020[29:31])
## As P7 is spread across a Sunday, Monday and Tuesday. Use the same average as P2 for a comparison.
AVG_P7_19= AVG_P2_19
## Creating a dataset using derived values for the average volume of traffic across each day in the restriction phase
COVID_Values= data.frame(Values=c(AVG_P1_19, AVG_P1_20, AVG_P2_19, AVG_P2_20, AVG_P3_19, AVG_P3_20, AVG_P4_19, AVG_P4_20, AVG_P5_19, AVG_P5_20, AVG_P6_19, AVG_P6_20, AVG_P7_19, AVG_P7_20),
Restriction_Phase= rep((c("P1","P2","P3","P4","P5","P6","P7")),each=2),
Year= rep(c("2019", "2020",
"2019", "2020",
"2019", "2020",
"2019", "2020",
"2019", "2020",
"2019", "2020",
"2019", "2020")))
## Modifying the data to include
BPLOT_COVID <- reshape(COVID_Values,
idvar = "Year",
timevar = "Restriction_Phase",
direction = "wide")
row.names(BPLOT_COVID) <- BPLOT_COVID$Year
BPLOT_COVID <- BPLOT_COVID[ , 2:ncol(BPLOT_COVID)]
colnames(BPLOT_COVID) <- c("P1","P2","P3","P4","P5","P6","P7")
BPLOT_COVID <- as.matrix(BPLOT_COVID)
BPLOT_COVID
## P1 P2 P3 P4 P5 P6 P7
## 2019 41939.84 38400.27 44999.0 40529.27 41525.5 44859 38400.27
## 2020 42305.71 33196.00 37550.5 28396.33 29145.5 24001 18343.67
barplot(height = BPLOT_COVID, main="Impact of COVID-19 restrictions on traffic during March 2020 in the CCT", xlab="Restriction Phase", ylab= "Avg Volume of cars per day", ylim=c(0,50000), legend=row.names(BPLOT_COVID), beside = TRUE)
abline(h=AVG_2019, col="red")
## Logging the difference of averages from 2019 to 2020 across each of the restriction phases.
Diff_P1= AVG_P1_19 - AVG_P1_20
Diff_P2= AVG_P2_19 - AVG_P2_20
Diff_P3= AVG_P3_19 - AVG_P3_20
Diff_P4= AVG_P4_19 - AVG_P4_20
Diff_P5= AVG_P5_19 - AVG_P5_20
Diff_P6= AVG_P6_19 - AVG_P6_20
Diff_P7= AVG_P7_19 - AVG_P7_20
Restriction_Phase= c(1:7)
Differences_Volume= c(Diff_P1, Diff_P2, Diff_P3, Diff_P4, Diff_P5, Diff_P6, Diff_P7)
plot(Differences_Volume, main="Differences of average traffic volume from 2019 to 2020 in each restriction phases", xlab="Restriction phase during March 2020", ylab= "Difference in Traffic Volume per day on average")
abline(lm(Differences_Volume~Restriction_Phase), col="red")
l=lm(Differences_Volume ~ Restriction_Phase)
cor(Differences_Volume, Restriction_Phase)
## [1] 0.9742988
l
##
## Call:
## lm(formula = Differences_Volume ~ Restriction_Phase)
##
## Coefficients:
## (Intercept) Restriction_Phase
## -2827 3482
## Deriving the approximate Proportion of (difference in daily volume from 2020 to 2019) with respect to the average volume per day during March 2019.
3482/AVG_2019
## [1] 0.08302369
Thus there is a strong positive correlation in the average traffic volume (per day) of the differences between 2019 and 2020 traffic with respect to the restriction period enforced (March 2020) as a result of the hysteric COVID pandemic-environment. This result can be interpreted as; with each new restriction enforced, the traffic volume in the cross-city tunnel decreases by approximately 3482 cars per day. Note this difference in cars per day as a portion of the 2019 average traffic volume per day is 8.3%.
This result can be useful for future political decision-makers in similar pandemic-circumstances (i.e. what restrictions to enforce and what impact this will have on the roadways of Sydney).
Amsler, S., & Shea, S. (2021, March 31). RFID (radio frequency identification). IoT Agenda. Retrieved October 22, 2022, from https://www.techtarget.com/iotagenda/definition/RFID-radio-frequency-identification
e-TAG. (2022, March 29). Wikipedia. https://en.wikipedia.org/wiki/E-TAG
Global Notes- nswtollroaddata.com. (n.d.). NSW Toll Road Data. https://nswtollroaddata.com/data-download/
Getting started | E-Toll. (n.d.). Transport for NSW. https://www.myetoll.transport.nsw.gov.au/help-and-faqs/getting-started
Stephen Duckett & Anika Stobart. (2021, August 30). Australia’s COVID-19 response: the story so far. Grattan Institute. Retrieved October 22, 2022, from https://grattan.edu.au/news/australias-covid-19-response-the-story-so-far/
Ozroads: Cross City Tunnel. (2007, March 31). Retrieved October 22, 2022, from https://www.ozroads.com.au/NSW/Freeways/CCT/cct.htm
Storen, R., & Corrigan, N. (2020, October 23). COVID-19: a chronology of state and territory government announcements (up until 30 June 2020). Retrieved October 22, 2022, from https://www.aph.gov.au/About_Parliament/Parliamentary_Departments/Parliamentary_Library/pubs/rp/rp2021/Chronologies/COVID-19StateTerritoryGovernmentAnnouncements
Gadiel, A. (2020, March 1). NSW under official lockdown — full details of new government directions now published. | Mills Oakley. Retrieved October 22, 2022, from https://www.millsoakley.com.au/thinking/nsw-under-official-lockdown-full-details-of-new-government-directions-now-published/