line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Sport::Analytics::NHL::Config; |
2
|
|
|
|
|
|
|
|
3
|
56
|
|
|
56
|
|
106055
|
use strict; |
|
56
|
|
|
|
|
124
|
|
|
56
|
|
|
|
|
1442
|
|
4
|
56
|
|
|
56
|
|
234
|
use warnings FATAL => 'all'; |
|
56
|
|
|
|
|
90
|
|
|
56
|
|
|
|
|
1974
|
|
5
|
|
|
|
|
|
|
|
6
|
56
|
|
|
56
|
|
1156
|
use parent 'Exporter'; |
|
56
|
|
|
|
|
693
|
|
|
56
|
|
|
|
|
226
|
|
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
=head1 NAME |
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
Sport::Analytics::NHL::Config - NHL-related configuration settings |
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
=head1 SYNOPSYS |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
NHL-related configuration settings |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
Provides NHL-related settings such as first and last season, teams, available reports, and so on. |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
This list shall expand as the release grows. |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
use Sport::Analytics::NHL::Config; |
21
|
|
|
|
|
|
|
print "The first active NHL season is $FIRST_SEASON\n"; |
22
|
|
|
|
|
|
|
|
23
|
|
|
|
|
|
|
=cut |
24
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
our $FIRST_SEASON = 1917; |
26
|
|
|
|
|
|
|
our @LOCKOUT_SEASONS = qw(2004); |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
our %DEFAULTED_GAMES = ( |
29
|
|
|
|
|
|
|
191720035 => 1, |
30
|
|
|
|
|
|
|
191720036 => 1, |
31
|
|
|
|
|
|
|
); |
32
|
|
|
|
|
|
|
our %TEAMS = ( |
33
|
|
|
|
|
|
|
MWN => { |
34
|
|
|
|
|
|
|
defunct => 1, |
35
|
|
|
|
|
|
|
long => [], |
36
|
|
|
|
|
|
|
short => [], |
37
|
|
|
|
|
|
|
full => [('Montreal Wanderers')], |
38
|
|
|
|
|
|
|
}, |
39
|
|
|
|
|
|
|
MMR => { |
40
|
|
|
|
|
|
|
defunct => 1, |
41
|
|
|
|
|
|
|
long => [], |
42
|
|
|
|
|
|
|
short => [], |
43
|
|
|
|
|
|
|
full => [('Montreal Maroons')], |
44
|
|
|
|
|
|
|
}, |
45
|
|
|
|
|
|
|
BRK => { |
46
|
|
|
|
|
|
|
defunct => 1, |
47
|
|
|
|
|
|
|
long => [], |
48
|
|
|
|
|
|
|
short => ['NYA'], |
49
|
|
|
|
|
|
|
full => [('Brooklyn Americans', 'New York Americans')], |
50
|
|
|
|
|
|
|
}, |
51
|
|
|
|
|
|
|
PIR => { |
52
|
|
|
|
|
|
|
long => [], |
53
|
|
|
|
|
|
|
defunct => 1, |
54
|
|
|
|
|
|
|
short => ['QUA'], |
55
|
|
|
|
|
|
|
full => [('Pittsburgh Pirates', 'Philadelphia Quakers')], |
56
|
|
|
|
|
|
|
}, |
57
|
|
|
|
|
|
|
VMA => { |
58
|
|
|
|
|
|
|
defunct => 1, |
59
|
|
|
|
|
|
|
long => [], |
60
|
|
|
|
|
|
|
short => ['VMI'], |
61
|
|
|
|
|
|
|
full => [('Vancouver Maroons', 'Vancouver Millionaires')], |
62
|
|
|
|
|
|
|
}, |
63
|
|
|
|
|
|
|
MET => { |
64
|
|
|
|
|
|
|
long => [], |
65
|
|
|
|
|
|
|
defunct => 1, |
66
|
|
|
|
|
|
|
short => ['SEA'], |
67
|
|
|
|
|
|
|
full => [('Seattle Metropolitans')], |
68
|
|
|
|
|
|
|
}, |
69
|
|
|
|
|
|
|
VIC => { |
70
|
|
|
|
|
|
|
long => [], |
71
|
|
|
|
|
|
|
defunct => 1, |
72
|
|
|
|
|
|
|
short => [], |
73
|
|
|
|
|
|
|
full => [('Victoria Cougars')], |
74
|
|
|
|
|
|
|
}, |
75
|
|
|
|
|
|
|
HAM => { |
76
|
|
|
|
|
|
|
defunct => 1, |
77
|
|
|
|
|
|
|
long => [], |
78
|
|
|
|
|
|
|
short => ['QBD'], |
79
|
|
|
|
|
|
|
full => [('Hamilton Tigers', 'Quebec Bulldogs')], |
80
|
|
|
|
|
|
|
}, |
81
|
|
|
|
|
|
|
CAT => { |
82
|
|
|
|
|
|
|
defunct => 1, |
83
|
|
|
|
|
|
|
long => [], |
84
|
|
|
|
|
|
|
short => [], |
85
|
|
|
|
|
|
|
full => [('Calgary Tigers')], |
86
|
|
|
|
|
|
|
}, |
87
|
|
|
|
|
|
|
EDE => { |
88
|
|
|
|
|
|
|
defunct => 1, |
89
|
|
|
|
|
|
|
long => [], |
90
|
|
|
|
|
|
|
short => [], |
91
|
|
|
|
|
|
|
full => [('Edmonton Eskimos')], |
92
|
|
|
|
|
|
|
}, |
93
|
|
|
|
|
|
|
SEN => { |
94
|
|
|
|
|
|
|
defunct => 1, |
95
|
|
|
|
|
|
|
long => [], |
96
|
|
|
|
|
|
|
short => ['SLE'], |
97
|
|
|
|
|
|
|
full => [('Ottawa Senators (1917)', 'St. Louis Eagles')], |
98
|
|
|
|
|
|
|
}, |
99
|
|
|
|
|
|
|
VGK => { |
100
|
|
|
|
|
|
|
long => [qw(Vegas Golden Knights)], |
101
|
|
|
|
|
|
|
short => [], |
102
|
|
|
|
|
|
|
full => [('Vegas Golden Knights', 'Las Vegas Golden Knights')], |
103
|
|
|
|
|
|
|
}, |
104
|
|
|
|
|
|
|
MIN => { |
105
|
|
|
|
|
|
|
long => [qw(Minnesota Wild)], |
106
|
|
|
|
|
|
|
short => [], |
107
|
|
|
|
|
|
|
full => [('Minnesota Wild')], |
108
|
|
|
|
|
|
|
}, |
109
|
|
|
|
|
|
|
WPG => { |
110
|
|
|
|
|
|
|
long => [qw(Winnipeg Jets Thrashers)], |
111
|
|
|
|
|
|
|
short => [qw(ATL)], |
112
|
|
|
|
|
|
|
full => [('Winnipeg Jets', 'Atlanta Thrashers')], |
113
|
|
|
|
|
|
|
}, |
114
|
|
|
|
|
|
|
NJD => { |
115
|
|
|
|
|
|
|
long => [qw(Devils Rockies Scouts), 'New Jersey'], |
116
|
|
|
|
|
|
|
short => [qw(CLR KCS NJD NJ N.J)], |
117
|
|
|
|
|
|
|
full => [('New Jersey Devils', 'Colorado Rockies', 'Kansas City Scouts')], |
118
|
|
|
|
|
|
|
}, |
119
|
|
|
|
|
|
|
ARI => { |
120
|
|
|
|
|
|
|
long => [qw(Arizona Phoenix Coyotes), 'Jets (1979)'], |
121
|
|
|
|
|
|
|
short => [qw(WIN PHX)], |
122
|
|
|
|
|
|
|
full => [('Arizona Coyotes', 'Phoenix Coyotes', 'Winnipeg Jets (1979)')] |
123
|
|
|
|
|
|
|
}, |
124
|
|
|
|
|
|
|
PIT => { |
125
|
|
|
|
|
|
|
long => [qw(Pittsburgh Penguins)], |
126
|
|
|
|
|
|
|
short => [qw()], |
127
|
|
|
|
|
|
|
full => [('Pittsburgh Penguins')], |
128
|
|
|
|
|
|
|
}, |
129
|
|
|
|
|
|
|
VAN => { |
130
|
|
|
|
|
|
|
long => [qw(Vancouver Canucks)], |
131
|
|
|
|
|
|
|
short => [qw()], |
132
|
|
|
|
|
|
|
full => [('Vancouver Canucks')], |
133
|
|
|
|
|
|
|
}, |
134
|
|
|
|
|
|
|
NYI => { |
135
|
|
|
|
|
|
|
long => [qw(Islanders), 'NY Islanders'], |
136
|
|
|
|
|
|
|
short => [qw()], |
137
|
|
|
|
|
|
|
full => [('New York Islanders')], |
138
|
|
|
|
|
|
|
}, |
139
|
|
|
|
|
|
|
CBJ => { |
140
|
|
|
|
|
|
|
long => [qw(Columbus Blue Jackets), 'Blue Jackets'], |
141
|
|
|
|
|
|
|
short => [qw(CBS)], |
142
|
|
|
|
|
|
|
full => [('Columbus Blue Jackets')], |
143
|
|
|
|
|
|
|
}, |
144
|
|
|
|
|
|
|
ANA => { |
145
|
|
|
|
|
|
|
long => [qw(Anaheim Ducks)], |
146
|
|
|
|
|
|
|
short => [qw()], |
147
|
|
|
|
|
|
|
full => [('Anaheim Ducks', 'Mighty Ducks Of Anaheim')], |
148
|
|
|
|
|
|
|
}, |
149
|
|
|
|
|
|
|
PHI => { |
150
|
|
|
|
|
|
|
long => [qw(Philadelphia Flyers)], |
151
|
|
|
|
|
|
|
short => [qw()], |
152
|
|
|
|
|
|
|
full => [('Philadelphia Flyers')], |
153
|
|
|
|
|
|
|
}, |
154
|
|
|
|
|
|
|
CAR => { |
155
|
|
|
|
|
|
|
long => [qw(Carolina Hurricanes Whalers)], |
156
|
|
|
|
|
|
|
short => [qw(HFD)], |
157
|
|
|
|
|
|
|
full => [('Carolina Hurricanes', 'Hartford Whalers')], |
158
|
|
|
|
|
|
|
}, |
159
|
|
|
|
|
|
|
NYR => { |
160
|
|
|
|
|
|
|
long => [qw(Rangers), 'NY Rangers'], |
161
|
|
|
|
|
|
|
short => [qw()], |
162
|
|
|
|
|
|
|
full => [('New York Rangers')], |
163
|
|
|
|
|
|
|
}, |
164
|
|
|
|
|
|
|
CGY => { |
165
|
|
|
|
|
|
|
long => [qw(Calgary Flames)], |
166
|
|
|
|
|
|
|
short => [qw(AFM)], |
167
|
|
|
|
|
|
|
full => [('Calgary Flames', 'Atlanta Flames')], |
168
|
|
|
|
|
|
|
}, |
169
|
|
|
|
|
|
|
BOS => { |
170
|
|
|
|
|
|
|
long => [qw(Boston Bruins)], |
171
|
|
|
|
|
|
|
short => [qw()], |
172
|
|
|
|
|
|
|
full => [('Boston Bruins')], |
173
|
|
|
|
|
|
|
}, |
174
|
|
|
|
|
|
|
CLE => { |
175
|
|
|
|
|
|
|
defunct => 1, |
176
|
|
|
|
|
|
|
long => [qw(Barons Seals)], |
177
|
|
|
|
|
|
|
short => [qw(CSE OAK CGS CBN)], |
178
|
|
|
|
|
|
|
full => [('Cleveland Barons', 'California Golden Seals', 'Oakland Seals')], |
179
|
|
|
|
|
|
|
}, |
180
|
|
|
|
|
|
|
EDM => { |
181
|
|
|
|
|
|
|
long => [qw(Edmonton Oilers)], |
182
|
|
|
|
|
|
|
short => [qw()], |
183
|
|
|
|
|
|
|
full => [('Edmonton Oilers')], |
184
|
|
|
|
|
|
|
}, |
185
|
|
|
|
|
|
|
MTL => { |
186
|
|
|
|
|
|
|
long => [qw(Canadiens Montreal)], |
187
|
|
|
|
|
|
|
short => [qw(MON)], |
188
|
|
|
|
|
|
|
full => [('Montreal Canadiens', 'Montréal Canadiens', 'Canadiens de Montreal', 'Canadiens Montreal', 'Canadien De Montreal')], |
189
|
|
|
|
|
|
|
}, |
190
|
|
|
|
|
|
|
STL => { |
191
|
|
|
|
|
|
|
long => [qw(Blues)], |
192
|
|
|
|
|
|
|
short => [qw()], |
193
|
|
|
|
|
|
|
full => [('St. Louis Blues', 'St.Louis Blues', 'St Louis', 'ST Louis Blues')], |
194
|
|
|
|
|
|
|
}, |
195
|
|
|
|
|
|
|
TOR => { |
196
|
|
|
|
|
|
|
long => [qw(Toronto Maple Leafs), 'Maple Leafs'], |
197
|
|
|
|
|
|
|
short => [qw(TOR TAN TSP)], |
198
|
|
|
|
|
|
|
full => [('Toronto Maple Leafs', 'Toronto Arenas', 'Toronto St. Patricks')], |
199
|
|
|
|
|
|
|
}, |
200
|
|
|
|
|
|
|
FLA => { |
201
|
|
|
|
|
|
|
long => [qw(Florida Panthers)], |
202
|
|
|
|
|
|
|
short => [qw(FLO)], |
203
|
|
|
|
|
|
|
full => [('Florida Panthers')], |
204
|
|
|
|
|
|
|
}, |
205
|
|
|
|
|
|
|
BUF => { |
206
|
|
|
|
|
|
|
long => [qw(Buffalo Sabres)], |
207
|
|
|
|
|
|
|
short => [qw()], |
208
|
|
|
|
|
|
|
full => [('Buffalo Sabres')], |
209
|
|
|
|
|
|
|
}, |
210
|
|
|
|
|
|
|
NSH => { |
211
|
|
|
|
|
|
|
long => [qw(Nashville Predators)], |
212
|
|
|
|
|
|
|
short => [qw()], |
213
|
|
|
|
|
|
|
full => [('Nashville Predators')], |
214
|
|
|
|
|
|
|
}, |
215
|
|
|
|
|
|
|
SJS => { |
216
|
|
|
|
|
|
|
long => [qw(San Jose Sharks), 'San Jose'], |
217
|
|
|
|
|
|
|
short => [qw(SJS S.J SJ)], |
218
|
|
|
|
|
|
|
full => [('San Jose Sharks')], |
219
|
|
|
|
|
|
|
}, |
220
|
|
|
|
|
|
|
COL => { |
221
|
|
|
|
|
|
|
long => [qw(Nordiques Colorado Avalanche)], |
222
|
|
|
|
|
|
|
short => [qw(QUE)], |
223
|
|
|
|
|
|
|
full => [('Colorado Avalanche', 'Quebec Nordiques')], |
224
|
|
|
|
|
|
|
}, |
225
|
|
|
|
|
|
|
DAL => { |
226
|
|
|
|
|
|
|
long => ['North Stars', qw(Dallas Stars)], |
227
|
|
|
|
|
|
|
short => [qw(MNS MINS)], |
228
|
|
|
|
|
|
|
full => [('Dallas Stars', 'Minnesota North Stars')], |
229
|
|
|
|
|
|
|
}, |
230
|
|
|
|
|
|
|
OTT => { |
231
|
|
|
|
|
|
|
long => [qw(Senators)], |
232
|
|
|
|
|
|
|
short => [qw()], |
233
|
|
|
|
|
|
|
full => [('Ottawa Senators')], |
234
|
|
|
|
|
|
|
}, |
235
|
|
|
|
|
|
|
LAK => { |
236
|
|
|
|
|
|
|
long => [qw(Kings), 'Los Angeles'], |
237
|
|
|
|
|
|
|
short => [qw(LAK L.A LA)], |
238
|
|
|
|
|
|
|
full => [('Los Angeles Kings')], |
239
|
|
|
|
|
|
|
}, |
240
|
|
|
|
|
|
|
TBL => { |
241
|
|
|
|
|
|
|
long => [qw(Lightning), 'Tampa Bay'], |
242
|
|
|
|
|
|
|
short => [qw(TBL T.B TB)], |
243
|
|
|
|
|
|
|
full => [('Tampa Bay Lightning')], |
244
|
|
|
|
|
|
|
}, |
245
|
|
|
|
|
|
|
DET => { |
246
|
|
|
|
|
|
|
long => [qw(Detroit Red Wings)], |
247
|
|
|
|
|
|
|
short => [qw(DCG DFL)], |
248
|
|
|
|
|
|
|
full => [('Detroit Red Wings', 'Detroit Cougars', 'Detroit Falcons')], |
249
|
|
|
|
|
|
|
}, |
250
|
|
|
|
|
|
|
CHI => { |
251
|
|
|
|
|
|
|
long => [('Blackhawks', 'Black Hawks', 'Chicago')], |
252
|
|
|
|
|
|
|
short => [qw()], |
253
|
|
|
|
|
|
|
full => [('Chicago Blackhawks', 'Chicago Black Hawks')], |
254
|
|
|
|
|
|
|
}, |
255
|
|
|
|
|
|
|
WSH => { |
256
|
|
|
|
|
|
|
long => [qw(Washington Capitals)], |
257
|
|
|
|
|
|
|
short => [qw(WAS)], |
258
|
|
|
|
|
|
|
full => [('Washington Capitals')], |
259
|
|
|
|
|
|
|
}, |
260
|
|
|
|
|
|
|
); |
261
|
|
|
|
|
|
|
|
262
|
|
|
|
|
|
|
our %FIRST_REPORT_SEASONS = ( |
263
|
|
|
|
|
|
|
BS => $FIRST_SEASON, |
264
|
|
|
|
|
|
|
#PB => 2010, |
265
|
|
|
|
|
|
|
GS => 1999, |
266
|
|
|
|
|
|
|
ES => 1999, |
267
|
|
|
|
|
|
|
PL => 2002, |
268
|
|
|
|
|
|
|
RO => 2005, |
269
|
|
|
|
|
|
|
); |
270
|
|
|
|
|
|
|
|
271
|
|
|
|
|
|
|
our $MAIN_GAME_FILE = 'BS.json'; |
272
|
|
|
|
|
|
|
our $SECONDARY_GAME_FILE = 'BS.html'; |
273
|
|
|
|
|
|
|
|
274
|
|
|
|
|
|
|
our $REGULAR = 2; |
275
|
|
|
|
|
|
|
our $PLAYOFF = 3; |
276
|
|
|
|
|
|
|
|
277
|
|
|
|
|
|
|
our $UNKNOWN_PLAYER_ID = 8000000; |
278
|
|
|
|
|
|
|
our $BENCH_PLAYER_ID = 8000001; |
279
|
|
|
|
|
|
|
our $COACH_PLAYER_ID = 8000002; |
280
|
|
|
|
|
|
|
our $EMPTY_NET_ID = 8000003; |
281
|
|
|
|
|
|
|
|
282
|
|
|
|
|
|
|
our %VOCABULARY = ( |
283
|
|
|
|
|
|
|
penalty => { |
284
|
|
|
|
|
|
|
'3 MINUTE MINOR' => [], |
285
|
|
|
|
|
|
|
'ABUSE OF OFFICIALS' => [ |
286
|
|
|
|
|
|
|
'ABUSE OF OFFICIASL', |
287
|
|
|
|
|
|
|
], |
288
|
|
|
|
|
|
|
'ABUSIVE LANGUAGE' => [], |
289
|
|
|
|
|
|
|
'ABUSIVE LANGUAGE - GAME' => [], |
290
|
|
|
|
|
|
|
'AGGRESSOR' => [], |
291
|
|
|
|
|
|
|
'ATTEMPT TO/DELIBERATE INJURY - MATCH PENALTY' => [ |
292
|
|
|
|
|
|
|
'ATTEMPT TO/DELIBERATE INJURY', |
293
|
|
|
|
|
|
|
'ATTEMPT TO INJURE', |
294
|
|
|
|
|
|
|
'MATCH - ATTEMPT TO INJURE', |
295
|
|
|
|
|
|
|
'ATTEMPT TO/DELIBERATE INJURY (MAT)', |
296
|
|
|
|
|
|
|
], |
297
|
|
|
|
|
|
|
'BENCH' => [], |
298
|
|
|
|
|
|
|
'BOARDING' => [ 'BOARD CHECK' ], |
299
|
|
|
|
|
|
|
'BUTT ENDING' => [], |
300
|
|
|
|
|
|
|
'CHARGING' => [], |
301
|
|
|
|
|
|
|
'CHECKING FROM BEHIND' => [], |
302
|
|
|
|
|
|
|
'CLIPPING' => [], |
303
|
|
|
|
|
|
|
'CLOSING HAND ON PUCK' => [ 'DELAYING GAME - SMOTHERING PUCK' ], |
304
|
|
|
|
|
|
|
'COACH/MGR ON ICE' => [ |
305
|
|
|
|
|
|
|
'COACG OR MANAGER ON THE ICE', |
306
|
|
|
|
|
|
|
'COACH OR MANAGER ON THE ICE', |
307
|
|
|
|
|
|
|
], |
308
|
|
|
|
|
|
|
'CONCEALING PUCK' => [], |
309
|
|
|
|
|
|
|
'COVERING PUCK IN CREASE' => [ 'COVERING PACK IN CREASE' ], |
310
|
|
|
|
|
|
|
'CROSS CHECKING', => [ 'CROSS CHECK' ], |
311
|
|
|
|
|
|
|
'DELAYING GAME - FACE - OFF VIOLATION' => [ |
312
|
|
|
|
|
|
|
'DELAYING THE GAME - FACE - OFF VIOLATION', |
313
|
|
|
|
|
|
|
'DELAY GM - FACE-OFF VIOLATION', |
314
|
|
|
|
|
|
|
'FACE-OFF VIOLATION', |
315
|
|
|
|
|
|
|
], |
316
|
|
|
|
|
|
|
'DELAYING GAME - ILL. PLAY GOALIE' => [ |
317
|
|
|
|
|
|
|
'DELAYING GAME - ILLEGAL PLAY BY GOALIE', |
318
|
|
|
|
|
|
|
'DELAYING GAME - ILLEGAL PLAY BY GOALKEEPER', |
319
|
|
|
|
|
|
|
'DELAY GAME - ILLEGAL PLAY GOAL', |
320
|
|
|
|
|
|
|
], |
321
|
|
|
|
|
|
|
'DELAYING GAME - PUCK OVER GLASS' => [ |
322
|
|
|
|
|
|
|
'DELAY GAME - PUCK OVER GLASS', |
323
|
|
|
|
|
|
|
'DELAYING GAME-PUCK OVER GLASS', |
324
|
|
|
|
|
|
|
], |
325
|
|
|
|
|
|
|
'DELAYING THE GAME' => [ 'DELAYING GAME', 'DELAY OF GAME' ], |
326
|
|
|
|
|
|
|
'DIVING' => [ |
327
|
|
|
|
|
|
|
'UNSPORTSMANLIKE CONDUCT DIVING', |
328
|
|
|
|
|
|
|
'EMBELLISHMENT', |
329
|
|
|
|
|
|
|
], |
330
|
|
|
|
|
|
|
'ELBOWING' => [], |
331
|
|
|
|
|
|
|
'FIGHTING' => [ 'FIGHTING (MAJ)' ], |
332
|
|
|
|
|
|
|
'GAME MISCONDUCT' => [], |
333
|
|
|
|
|
|
|
'GAME MISCONDUCT - TEAM STAFF' => [], |
334
|
|
|
|
|
|
|
'GAME MISCONDUCT - HEAD COACH' => [ 'GAME MISCONDUCT - HEAD' ], |
335
|
|
|
|
|
|
|
'GOALIE LEAVE CREASE' => [], |
336
|
|
|
|
|
|
|
"GOALIE PARTICIPAT'N BYD CENTER" => [ |
337
|
|
|
|
|
|
|
'GOALIE PARTICIPATION BEYOND CENTER', |
338
|
|
|
|
|
|
|
'GOALKEEPER PARTICIPATION BEYOND CENTER', |
339
|
|
|
|
|
|
|
], |
340
|
|
|
|
|
|
|
'GOALKEEPER DISPLACED NET' => [], |
341
|
|
|
|
|
|
|
'GROSS MISCONDUCT' => [ |
342
|
|
|
|
|
|
|
'20 MINUTE MATCH', |
343
|
|
|
|
|
|
|
'MATCH PENALTY', |
344
|
|
|
|
|
|
|
], |
345
|
|
|
|
|
|
|
'HEAD BUTTING' => [], |
346
|
|
|
|
|
|
|
'HEAD BUTTING - GAME' => [], |
347
|
|
|
|
|
|
|
'HI-STICKING' => [ |
348
|
|
|
|
|
|
|
'HI STICK', |
349
|
|
|
|
|
|
|
], |
350
|
|
|
|
|
|
|
'HOLDING' => [], |
351
|
|
|
|
|
|
|
'HOLDING ON BREAKAWAY' => [], |
352
|
|
|
|
|
|
|
'HOLDING THE STICK' => [ 'HOLDING STICK' ], |
353
|
|
|
|
|
|
|
'HOLDING STICK ON BREAKAWAY' => [], |
354
|
|
|
|
|
|
|
HOOKING => [], |
355
|
|
|
|
|
|
|
'HOOKING ON BREAKAWAY' => [], |
356
|
|
|
|
|
|
|
'ILLEGAL EQUIPMENT' => [], |
357
|
|
|
|
|
|
|
'ILLEGAL STICK' => [ 'BROKEN STICK' ], |
358
|
|
|
|
|
|
|
'ILLEGAL SUBSTITUTION' => [], |
359
|
|
|
|
|
|
|
'ILLEGAL CHECK TO HEAD' => [], |
360
|
|
|
|
|
|
|
'INELIGIBLE PLAYER' => [], |
361
|
|
|
|
|
|
|
'INSTIGATOR' => [], |
362
|
|
|
|
|
|
|
'INSTIGATOR - FACE SHIELD' => [], |
363
|
|
|
|
|
|
|
'INSTIGATOR - MISCONDUCT' => [], |
364
|
|
|
|
|
|
|
'INTERFERENCE' => [], |
365
|
|
|
|
|
|
|
'INTERFERENCE ON GOALKEEPER' => [ |
366
|
|
|
|
|
|
|
'INTERFERENCE - GOALKEEPER', |
367
|
|
|
|
|
|
|
'INTERFERENCE - GOALTENDER', |
368
|
|
|
|
|
|
|
'INTERFERENCE-ON THE GOALTENDER' |
369
|
|
|
|
|
|
|
], |
370
|
|
|
|
|
|
|
'INTERFERE W/ OFFICIAL' => [ 'INTERFERENCE WITH OFFICIAL' ], |
371
|
|
|
|
|
|
|
'KICKING' => [], |
372
|
|
|
|
|
|
|
'KNEEING' => [], |
373
|
|
|
|
|
|
|
'LATE ON ICE' => [], |
374
|
|
|
|
|
|
|
'LEAVING PENALTY BOX' => [], |
375
|
|
|
|
|
|
|
'LEAVING PLAYER\'S/PENALTY BENCH' => [ |
376
|
|
|
|
|
|
|
'PLAYER LEAVES BENCH', |
377
|
|
|
|
|
|
|
'PLAYERS LEAVING BENCH', |
378
|
|
|
|
|
|
|
], |
379
|
|
|
|
|
|
|
'MATCH - DELIBERATE INJURY' => [ 'DELIBERATE INJURY' ], |
380
|
|
|
|
|
|
|
'MISCONDUCT' => [], |
381
|
|
|
|
|
|
|
'NET DISPLACED' => [], |
382
|
|
|
|
|
|
|
'NOT PROC. TO DRESS.RM.' => [ |
383
|
|
|
|
|
|
|
'NOT PROCEDING TO DRESSING ROOM', |
384
|
|
|
|
|
|
|
'NOT PROCEEDING TO DRESSING ROOM', |
385
|
|
|
|
|
|
|
], |
386
|
|
|
|
|
|
|
'NOT PROCEEDING DIR PEN/BOX' => [ 'NOT PROCEEDING DIRECTLY TO PENALTY BOX' ], |
387
|
|
|
|
|
|
|
'OBJECTS ON ICE' => [], |
388
|
|
|
|
|
|
|
'PICKING UP PUCK IN CREASE' => [], |
389
|
|
|
|
|
|
|
'PUCK THROWN FWD - GOALKEEPER' => [ 'PUCK THROWN FORWARD - GOALKEEPER' ], |
390
|
|
|
|
|
|
|
'REFUSAL TO PLAY' => [], |
391
|
|
|
|
|
|
|
'REMOVING SWEATER' => [], |
392
|
|
|
|
|
|
|
ROUGHING => [], |
393
|
|
|
|
|
|
|
SLASHING => [], |
394
|
|
|
|
|
|
|
'SLASH ON BREAKAWAY' => [], |
395
|
|
|
|
|
|
|
'SPEARING' => [], |
396
|
|
|
|
|
|
|
'THROWING OBJECT ON ICE' => [], |
397
|
|
|
|
|
|
|
'THROW OBJECT AT PUCK' => [ |
398
|
|
|
|
|
|
|
'THOW OBJECT AT PU{', |
399
|
|
|
|
|
|
|
'THOW OBJECT AT PUCK', |
400
|
|
|
|
|
|
|
], |
401
|
|
|
|
|
|
|
'THROWING STICK' => [], |
402
|
|
|
|
|
|
|
'TOO MANY MEN/ICE' => [ 'TOO MANY MEN/ICE - BENCH', 'TOO MANY MEN ON THE ICE' ], |
403
|
|
|
|
|
|
|
TRIPPING => [], |
404
|
|
|
|
|
|
|
'TRIPPING ON BREAKAWAY' => [], |
405
|
|
|
|
|
|
|
'UNNECESSARY ROUGHNESS' => [], |
406
|
|
|
|
|
|
|
'UNSPORTSMANLIKE CONDUCT' => [], |
407
|
|
|
|
|
|
|
'UNSPORTSMANLIKE CONDUCT - COACH' => [], |
408
|
|
|
|
|
|
|
'UNKNOWN' => [ |
409
|
|
|
|
|
|
|
'PENALTY SHOT', |
410
|
|
|
|
|
|
|
'MAJOR', |
411
|
|
|
|
|
|
|
'MINOR', |
412
|
|
|
|
|
|
|
], |
413
|
|
|
|
|
|
|
'ABUSIVE LANGUAGE - MISCONDUCT' => [], |
414
|
|
|
|
|
|
|
}, |
415
|
|
|
|
|
|
|
stopreason => { |
416
|
|
|
|
|
|
|
'CHALLENGE AWAY: OFF-SIDE' => [ 'CHLG VIS - OFF-SIDE' ], |
417
|
|
|
|
|
|
|
'CHALLENGE HOME: OFF-SIDE' => [ 'CHLG HM - OFF-SIDE' ], |
418
|
|
|
|
|
|
|
'CHALLENGE LEAGUE: OFF-SIDE' => [ 'CHLG LEAGUE - OFF-SIDE' ], |
419
|
|
|
|
|
|
|
'CHALLENGE LEAGUE: GOALIE INTERFERENCE' => [ 'CHLG LEAGUE- GOAL INTERFERENCE' ], |
420
|
|
|
|
|
|
|
'CHALLENGE HOME: GOALIE INTERFERENCE' => [ 'CHLG HM - GOAL INTERFERENCE', ], |
421
|
|
|
|
|
|
|
'CHALLENGE AWAY: GOALIE INTERFERENCE' => [ 'CHLG VIS - GOAL INTERFERENCE' ], |
422
|
|
|
|
|
|
|
'GOALIE STOPPED' => [], |
423
|
|
|
|
|
|
|
'HIGH STICK' => [], |
424
|
|
|
|
|
|
|
'HOME TIMEOUT' => [ 'TIME OUT - HOME' ], |
425
|
|
|
|
|
|
|
ICING => [], |
426
|
|
|
|
|
|
|
OFFSIDE => [], |
427
|
|
|
|
|
|
|
'OFFSIDES PASS' => [], |
428
|
|
|
|
|
|
|
'PUCK IN NETTING' => [], |
429
|
|
|
|
|
|
|
'PUCK IN CROWD' => [], |
430
|
|
|
|
|
|
|
'REFEREE OR LINESMAN' => [ |
431
|
|
|
|
|
|
|
'OFFICIAL INJURY', |
432
|
|
|
|
|
|
|
'REFEREE', |
433
|
|
|
|
|
|
|
'LINESMAN', |
434
|
|
|
|
|
|
|
], |
435
|
|
|
|
|
|
|
'TV TIMEOUT' => [], |
436
|
|
|
|
|
|
|
'PUCK FROZEN' => [], |
437
|
|
|
|
|
|
|
'NET OFF POST' => [], |
438
|
|
|
|
|
|
|
'TIME OUT - VISITOR' => [ 'VISITOR TIMEOUT' ], |
439
|
|
|
|
|
|
|
'HAND PASS' => [], |
440
|
|
|
|
|
|
|
'PREMATURE SUBSTITUTION' => [], |
441
|
|
|
|
|
|
|
'INJURY' => [ 'PLAYER INJURY' ], |
442
|
|
|
|
|
|
|
'RINK REPAIR' => [ 'ICE PROBLEM' ], |
443
|
|
|
|
|
|
|
'OBJECTS ON ICE' => [], |
444
|
|
|
|
|
|
|
'CLOCK PROBLEM' => [], |
445
|
|
|
|
|
|
|
UNKNOWN => [], |
446
|
|
|
|
|
|
|
'PUCK IN BENCHES' => [], |
447
|
|
|
|
|
|
|
'INVALID SHOOTOUT EVENT: ICING' => [], |
448
|
|
|
|
|
|
|
'NET OFF' => [], |
449
|
|
|
|
|
|
|
'VIDEO REVIEW' => [], |
450
|
|
|
|
|
|
|
'PLAYER EQUIPMENT' => [], |
451
|
|
|
|
|
|
|
'SWITCH SIDES' => [], |
452
|
|
|
|
|
|
|
}, |
453
|
|
|
|
|
|
|
miss => { |
454
|
|
|
|
|
|
|
WIDE => [ 'WIDE OF NET' ], |
455
|
|
|
|
|
|
|
CROSSBAR => [ 'HIT CROSSBAR' ], |
456
|
|
|
|
|
|
|
OVER => [ 'OVER NET' ], |
457
|
|
|
|
|
|
|
GOALPOST => [], |
458
|
|
|
|
|
|
|
UNKNOWN => [ '' ], |
459
|
|
|
|
|
|
|
}, |
460
|
|
|
|
|
|
|
shot_type => { |
461
|
|
|
|
|
|
|
SLAP => [ 'SLAP SHOT' ], |
462
|
|
|
|
|
|
|
SNAP => [ 'SNAP SHOT' ], |
463
|
|
|
|
|
|
|
WRIST => [ 'WRIST SHOT' ], |
464
|
|
|
|
|
|
|
BACKHAND => [], |
465
|
|
|
|
|
|
|
'TIP-IN' => [], |
466
|
|
|
|
|
|
|
UNKNOWN => [ '', ' ' ], |
467
|
|
|
|
|
|
|
'WRAP-AROUND' => [], |
468
|
|
|
|
|
|
|
DEFLECTED => [], |
469
|
|
|
|
|
|
|
}, |
470
|
|
|
|
|
|
|
strength => { |
471
|
|
|
|
|
|
|
'EV' => [ 'EVEN' ], |
472
|
|
|
|
|
|
|
'PP' => [ 'PPG' ], |
473
|
|
|
|
|
|
|
'SH' => [ 'SHG' ], |
474
|
|
|
|
|
|
|
'PS' => [], |
475
|
|
|
|
|
|
|
'XX' => [ '', ' ' ], |
476
|
|
|
|
|
|
|
}, |
477
|
|
|
|
|
|
|
events => { |
478
|
|
|
|
|
|
|
BLOCK => [ 'BLOCKED_SHOT' ], |
479
|
|
|
|
|
|
|
CHL => [ 'CHALLENGE' ], |
480
|
|
|
|
|
|
|
FAC => [ 'FACEOFF' ], |
481
|
|
|
|
|
|
|
GEND => [ 'GAME_END' ], |
482
|
|
|
|
|
|
|
GIVE => [ 'GIVEAWAY' ], |
483
|
|
|
|
|
|
|
GOAL => [], |
484
|
|
|
|
|
|
|
HIT => [], |
485
|
|
|
|
|
|
|
MISS => [ 'MISSED_SHOT' ], |
486
|
|
|
|
|
|
|
PEND => [ 'PERIOD_END' ], |
487
|
|
|
|
|
|
|
PENL => [ 'PENALTY', 'FIGHT' ], |
488
|
|
|
|
|
|
|
PSTR => [ 'PERIOD_START' ], |
489
|
|
|
|
|
|
|
SHOT => [], |
490
|
|
|
|
|
|
|
STOP => [], |
491
|
|
|
|
|
|
|
TAKE => [ 'TAKEAWAY' ], |
492
|
|
|
|
|
|
|
}, |
493
|
|
|
|
|
|
|
); |
494
|
|
|
|
|
|
|
|
495
|
|
|
|
|
|
|
our %DATA_BY_SEASON = ( |
496
|
|
|
|
|
|
|
attendance => 2010, |
497
|
|
|
|
|
|
|
coordinates => 2010, |
498
|
|
|
|
|
|
|
location => 1997, |
499
|
|
|
|
|
|
|
officials => 2011, |
500
|
|
|
|
|
|
|
on_ice => 2007, |
501
|
|
|
|
|
|
|
pb_list => 2018, |
502
|
|
|
|
|
|
|
periods => 2010, |
503
|
|
|
|
|
|
|
severity => 2010, |
504
|
|
|
|
|
|
|
shot_types => 2008, |
505
|
|
|
|
|
|
|
stars => 1998, |
506
|
|
|
|
|
|
|
strength => 1998, |
507
|
|
|
|
|
|
|
); |
508
|
|
|
|
|
|
|
|
509
|
|
|
|
|
|
|
our %STAT_RECORD_FROM = ( |
510
|
|
|
|
|
|
|
assists => $FIRST_SEASON, |
511
|
|
|
|
|
|
|
goals => $FIRST_SEASON, |
512
|
|
|
|
|
|
|
number => $FIRST_SEASON, |
513
|
|
|
|
|
|
|
penaltyMinutes => $FIRST_SEASON, |
514
|
|
|
|
|
|
|
pim => $FIRST_SEASON, |
515
|
|
|
|
|
|
|
timeOnIce => $FIRST_SEASON, |
516
|
|
|
|
|
|
|
shots => 1959, |
517
|
|
|
|
|
|
|
plusMinus => 1959, |
518
|
|
|
|
|
|
|
powerPlayGoals => 1933, |
519
|
|
|
|
|
|
|
powerPlayAssists => 1933, |
520
|
|
|
|
|
|
|
saves => 1955, |
521
|
|
|
|
|
|
|
shortHandedGoals => 1933, |
522
|
|
|
|
|
|
|
shortHandedAssists => 1933, |
523
|
|
|
|
|
|
|
evenSaves => 1997, |
524
|
|
|
|
|
|
|
evenShotsAgainst => 1997, |
525
|
|
|
|
|
|
|
evenTimeOnIce => 1997, |
526
|
|
|
|
|
|
|
faceoffTaken => 1997, |
527
|
|
|
|
|
|
|
faceOffWins => 1997, |
528
|
|
|
|
|
|
|
powerPlaySaves => 1997, |
529
|
|
|
|
|
|
|
powerPlayShotsAgainst => 1997, |
530
|
|
|
|
|
|
|
powerPlayTimeOnIce => 1997, |
531
|
|
|
|
|
|
|
shortHandedSaves => 1997, |
532
|
|
|
|
|
|
|
shortHandedShotsAgainst => 1997, |
533
|
|
|
|
|
|
|
shortHandedTimeOnIce => 1997, |
534
|
|
|
|
|
|
|
start => 2003, |
535
|
|
|
|
|
|
|
blocked => 2010, # 1998 in html |
536
|
|
|
|
|
|
|
giveaways => 2010, # 1998 not in html |
537
|
|
|
|
|
|
|
hits => 2010, # 1998 in html |
538
|
|
|
|
|
|
|
takeaways => 2010, # 1998 in html |
539
|
|
|
|
|
|
|
); |
540
|
|
|
|
|
|
|
|
541
|
|
|
|
|
|
|
our %REASONABLE_EVENTS = ( |
542
|
|
|
|
|
|
|
old => 1, new => 150, |
543
|
|
|
|
|
|
|
); |
544
|
|
|
|
|
|
|
|
545
|
|
|
|
|
|
|
our %PENALTY_POSSIBLE_NO_OFFENDER = ( |
546
|
|
|
|
|
|
|
'TOO MANY MEN/ICE' => 1, |
547
|
|
|
|
|
|
|
'DELAYING THE GAME' => 1, |
548
|
|
|
|
|
|
|
'ABUSE OF OFFICIALS' => 1, |
549
|
|
|
|
|
|
|
'ABUSIVE LANGUAGE' => 1, |
550
|
|
|
|
|
|
|
'NOT PROCEEDING DIR PEN/BOX' => 1, |
551
|
|
|
|
|
|
|
'UNSPORTSMANLIKE CONDUCT' => 1, |
552
|
|
|
|
|
|
|
'UNKNOWN' => 1, |
553
|
|
|
|
|
|
|
'LATE ON ICE' => 1, |
554
|
|
|
|
|
|
|
'ILLEGAL SUBSTITUTION' => 1, |
555
|
|
|
|
|
|
|
'LEAVING PLAYER\'S/PENALTY BENCH' => 1, |
556
|
|
|
|
|
|
|
'OBJECTS ON ICE' => 1, |
557
|
|
|
|
|
|
|
'UNSPORTSMANLIKE CONDUCT - COACH' => 1, |
558
|
|
|
|
|
|
|
'GROSS MISCONDUCT' => 1, |
559
|
|
|
|
|
|
|
); |
560
|
|
|
|
|
|
|
|
561
|
|
|
|
|
|
|
our %REVERSE_STAT = ( |
562
|
|
|
|
|
|
|
HIT => 'received_hit', |
563
|
|
|
|
|
|
|
BLOCK => 'shot_blocked', |
564
|
|
|
|
|
|
|
PENL => 'drew_penalty', |
565
|
|
|
|
|
|
|
GOAL => 'goals_against', |
566
|
|
|
|
|
|
|
); |
567
|
|
|
|
|
|
|
|
568
|
|
|
|
|
|
|
our $LAST_PLAYOFF_GAME_INDEX = 417; |
569
|
|
|
|
|
|
|
our $LATE_START_IN_2012 = 1367330000; |
570
|
|
|
|
|
|
|
|
571
|
|
|
|
|
|
|
our @EXPORT = qw( |
572
|
|
|
|
|
|
|
$REGULAR $PLAYOFF $LAST_PLAYOFF_GAME_INDEX $LATE_START_IN_2012 %DEFAULTED_GAMES |
573
|
|
|
|
|
|
|
$FIRST_SEASON @LOCKOUT_SEASONS %FIRST_REPORT_SEASONS |
574
|
|
|
|
|
|
|
$MAIN_GAME_FILE $SECONDARY_GAME_FILE |
575
|
|
|
|
|
|
|
%TEAMS |
576
|
|
|
|
|
|
|
$UNKNOWN_PLAYER_ID $BENCH_PLAYER_ID $COACH_PLAYER_ID $EMPTY_NET_ID |
577
|
|
|
|
|
|
|
%VOCABULARY |
578
|
|
|
|
|
|
|
%DATA_BY_SEASON %STAT_RECORD_FROM %REASONABLE_EVENTS |
579
|
|
|
|
|
|
|
%PENALTY_POSSIBLE_NO_OFFENDER |
580
|
|
|
|
|
|
|
%ZERO_EVENT_GAMES |
581
|
|
|
|
|
|
|
%REVERSE_STAT |
582
|
|
|
|
|
|
|
); |
583
|
|
|
|
|
|
|
|
584
|
|
|
|
|
|
|
our %ZERO_EVENT_GAMES = ( |
585
|
|
|
|
|
|
|
194320118 => 1, |
586
|
|
|
|
|
|
|
); |
587
|
|
|
|
|
|
|
|
588
|
|
|
|
|
|
|
1; |
589
|
|
|
|
|
|
|
|
590
|
|
|
|
|
|
|
=head1 AUTHOR |
591
|
|
|
|
|
|
|
|
592
|
|
|
|
|
|
|
More Hockey Stats, C<< >> |
593
|
|
|
|
|
|
|
|
594
|
|
|
|
|
|
|
=head1 BUGS |
595
|
|
|
|
|
|
|
|
596
|
|
|
|
|
|
|
Please report any bugs or feature requests to C, or through |
597
|
|
|
|
|
|
|
the web interface at L. I will be notified, and then you'll |
598
|
|
|
|
|
|
|
automatically be notified of progress on your bug as I make changes. |
599
|
|
|
|
|
|
|
|
600
|
|
|
|
|
|
|
|
601
|
|
|
|
|
|
|
=head1 SUPPORT |
602
|
|
|
|
|
|
|
|
603
|
|
|
|
|
|
|
You can find documentation for this module with the perldoc command. |
604
|
|
|
|
|
|
|
|
605
|
|
|
|
|
|
|
perldoc Sport::Analytics::NHL::Config |
606
|
|
|
|
|
|
|
|
607
|
|
|
|
|
|
|
|
608
|
|
|
|
|
|
|
You can also look for information at: |
609
|
|
|
|
|
|
|
|
610
|
|
|
|
|
|
|
=over 4 |
611
|
|
|
|
|
|
|
|
612
|
|
|
|
|
|
|
=item * RT: CPAN's request tracker (report bugs here) |
613
|
|
|
|
|
|
|
|
614
|
|
|
|
|
|
|
L |
615
|
|
|
|
|
|
|
|
616
|
|
|
|
|
|
|
=item * AnnoCPAN: Annotated CPAN documentation |
617
|
|
|
|
|
|
|
|
618
|
|
|
|
|
|
|
L |
619
|
|
|
|
|
|
|
|
620
|
|
|
|
|
|
|
=item * CPAN Ratings |
621
|
|
|
|
|
|
|
|
622
|
|
|
|
|
|
|
L |
623
|
|
|
|
|
|
|
|
624
|
|
|
|
|
|
|
=item * Search CPAN |
625
|
|
|
|
|
|
|
|
626
|
|
|
|
|
|
|
L |
627
|
|
|
|
|
|
|
|
628
|
|
|
|
|
|
|
=back |
629
|
|
|
|
|
|
|
|