Hello everyone! I have a huge dataset with 270864 observations on gross hourly wage split into different quarters from years 2012 to 2020. Here is the example of my dataset:

Code:
* Example generated by -dataex-. To install: ssc install dataex
clear
input double avg_gross_hourly_ea float qdate byte prf_group float(gender ter)
18.86 224 6 3 1
26.34 232 2 3 1
17.28 223 2 2 2
21.42 218 6 3 1
12.95 229 4 3 2
 26.3 212 2 2 1
17.82 221 2 1 2
14.81 215 5 1 2
22.54 233 6 1 1
11.19 228 4 1 2
15.18 231 3 1 2
12.29 233 4 2 2
17.15 241 4 2 1
15.65 225 6 3 2
21.49 235 3 3 2
37.76 241 1 3 2
    . 239 6 2 2
21.78 214 3 3 1
26.31 225 2 2 1
14.43 208 5 3 1
    . 225 5 2 2
29.59 225 6 2 1
41.86 237 6 2 1
19.67 219 2 3 2
 36.5 228 6 2 1
44.11 226 1 2 2
43.53 213 6 3 1
 11.2 217 5 1 2
    . 218 1 1 2
    . 221 3 2 2
20.73 226 6 1 1
 26.4 218 2 3 1
43.87 225 1 2 1
10.26 213 4 3 2
14.22 225 3 1 2
39.72 239 2 1 1
23.69 211 2 1 1
12.18 225 4 3 2
33.14 217 1 2 1
17.56 226 3 2 2
27.92 225 3 3 1
12.59 221 5 1 1
 32.4 239 1 3 2
    . 238 6 3 2
14.11 242 5 3 2
32.25 219 1 3 2
12.28 229 5 3 2
20.68 208 3 3 1
22.05 213 1 1 2
41.56 227 1 2 1
24.78 214 2 1 1
21.33 211 6 2 1
12.06 217 3 2 2
40.32 226 1 2 1
29.81 219 2 2 1
    . 228 1 1 2
16.96 233 4 1 1
 30.7 234 6 3 1
14.21 220 5 2 1
17.63 225 3 3 2
35.37 209 1 1 2
15.57 233 4 1 1
21.97 224 1 1 2
22.46 239 3 2 1
12.28 218 3 3 2
14.74 216 3 1 2
16.43 240 4 3 1
20.62 224 3 1 1
    . 221 6 1 1
 17.3 233 3 1 2
17.36 216 2 1 2
12.26 211 5 2 2
22.42 240 6 3 2
18.86 236 4 1 1
  8.7 209 5 1 2
22.42 225 6 2 2
28.31 208 3 2 1
21.86 225 2 3 1
13.27 212 4 1 1
42.24 232 1 1 1
14.02 215 3 2 2
16.51 242 3 3 2
14.24 221 4 3 1
26.82 217 2 2 1
10.45 231 5 2 2
22.86 233 6 1 1
14.34 208 6 2 2
35.19 221 1 2 2
44.58 237 1 1 1
14.13 210 4 3 1
17.35 235 4 2 1
20.66 243 3 3 1
22.55 225 3 3 1
16.75 242 6 1 2
22.55 221 2 2 1
32.53 225 1 3 2
14.48 209 5 1 1
15.74 241 3 2 2
12.43 231 4 1 2
26.64 236 2 1 2
end
format %tq qdate
label values prf_group prf_group
label def prf_group 1 "unskilled", modify
label def prf_group 2 "semiskilled", modify
label def prf_group 3 "skilled", modify
label def prf_group 4 "highly qualified", modify
label def prf_group 5 "executive staff", modify
label def prf_group 6 "total", modify
label values gender gender
label def gender 1 "Female", modify
label def gender 2 "Male", modify
label def gender 3 "Total", modify
label values ter ter1
label def ter1 1 "Former territory of the Federal Republic", modify
label def ter1 2 "New Lander", modify
I want to create this table (taken from http://nbn-resolving.de/urn:nbn:de:101:1-201602176403) with my variables "prf_group", "gender" "ter" corresponding each to the labels defined in the code, except for the fact that I have different territories.
Thanks to anyone you who can share some tips/advices on how to handle this dataset.
Array