Class: NBA::BoxScorePlayerTrackTeamStat

Inherits:
Shale::Mapper
  • Object
show all
Defined in:
lib/nba/box_score_player_track_team_stat.rb

Overview

Represents player tracking statistics for a team in a game

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#astInteger

Returns assists

Examples:

stat.ast #=> 28


135
# File 'lib/nba/box_score_player_track_team_stat.rb', line 135

attribute :ast, Shale::Type::Integer

#cfg_pctFloat

Returns contested field goal percentage

Examples:

stat.cfg_pct #=> 0.400


159
# File 'lib/nba/box_score_player_track_team_stat.rb', line 159

attribute :cfg_pct, Shale::Type::Float

#cfgaInteger

Returns contested field goals attempted

Examples:

stat.cfga #=> 45


151
# File 'lib/nba/box_score_player_track_team_stat.rb', line 151

attribute :cfga, Shale::Type::Integer

#cfgmInteger

Returns contested field goals made

Examples:

stat.cfgm #=> 18


143
# File 'lib/nba/box_score_player_track_team_stat.rb', line 143

attribute :cfgm, Shale::Type::Integer

#dfg_pctFloat

Returns defended field goal percentage

Examples:

stat.dfg_pct #=> 0.455


207
# File 'lib/nba/box_score_player_track_team_stat.rb', line 207

attribute :dfg_pct, Shale::Type::Float

#dfgaInteger

Returns defended field goals attempted

Examples:

stat.dfga #=> 55


199
# File 'lib/nba/box_score_player_track_team_stat.rb', line 199

attribute :dfga, Shale::Type::Integer

#dfgmInteger

Returns defended field goals made

Examples:

stat.dfgm #=> 25


191
# File 'lib/nba/box_score_player_track_team_stat.rb', line 191

attribute :dfgm, Shale::Type::Integer

#distanceFloat

Returns total team distance traveled in miles

Examples:

stat.distance #=> 24.5


71
# File 'lib/nba/box_score_player_track_team_stat.rb', line 71

attribute :distance, Shale::Type::Float

#dreb_chancesInteger

Returns defensive rebound chances

Examples:

stat.dreb_chances #=> 45


87
# File 'lib/nba/box_score_player_track_team_stat.rb', line 87

attribute :dreb_chances, Shale::Type::Integer

#ft_astInteger

Returns free throw assists

Examples:

stat.ft_ast #=> 5


119
# File 'lib/nba/box_score_player_track_team_stat.rb', line 119

attribute :ft_ast, Shale::Type::Integer

#game_idString

Returns the game ID

Examples:

stat.game_id #=> "0022400001"


15
# File 'lib/nba/box_score_player_track_team_stat.rb', line 15

attribute :game_id, Shale::Type::String

#minString

Returns minutes played

Examples:

stat.min #=> "240:00"


55
# File 'lib/nba/box_score_player_track_team_stat.rb', line 55

attribute :min, Shale::Type::String

#oreb_chancesInteger

Returns offensive rebound chances

Examples:

stat.oreb_chances #=> 35


79
# File 'lib/nba/box_score_player_track_team_stat.rb', line 79

attribute :oreb_chances, Shale::Type::Integer

#passesInteger

Returns total passes

Examples:

stat.passes #=> 285


127
# File 'lib/nba/box_score_player_track_team_stat.rb', line 127

attribute :passes, Shale::Type::Integer

#reb_chancesInteger

Returns total rebound chances

Examples:

stat.reb_chances #=> 80


95
# File 'lib/nba/box_score_player_track_team_stat.rb', line 95

attribute :reb_chances, Shale::Type::Integer

#secondary_astInteger

Returns secondary assists

Examples:

stat.secondary_ast #=> 12


111
# File 'lib/nba/box_score_player_track_team_stat.rb', line 111

attribute :secondary_ast, Shale::Type::Integer

#speedFloat

Returns team average speed in miles per hour

Examples:

stat.speed #=> 4.38


63
# File 'lib/nba/box_score_player_track_team_stat.rb', line 63

attribute :speed, Shale::Type::Float

#team_abbreviationString

Returns the team abbreviation

Examples:

stat.team_abbreviation #=> "GSW"


39
# File 'lib/nba/box_score_player_track_team_stat.rb', line 39

attribute :team_abbreviation, Shale::Type::String

#team_cityString

Returns the team city

Examples:

stat.team_city #=> "Golden State"


47
# File 'lib/nba/box_score_player_track_team_stat.rb', line 47

attribute :team_city, Shale::Type::String

#team_idInteger

Returns the team ID

Examples:

stat.team_id #=> 1610612744


23
# File 'lib/nba/box_score_player_track_team_stat.rb', line 23

attribute :team_id, Shale::Type::Integer

#team_nameString

Returns the team name

Examples:

stat.team_name #=> "Warriors"


31
# File 'lib/nba/box_score_player_track_team_stat.rb', line 31

attribute :team_name, Shale::Type::String

#touchesInteger

Returns total touches

Examples:

stat.touches #=> 350


103
# File 'lib/nba/box_score_player_track_team_stat.rb', line 103

attribute :touches, Shale::Type::Integer

#ufg_pctFloat

Returns uncontested field goal percentage

Examples:

stat.ufg_pct #=> 0.686


183
# File 'lib/nba/box_score_player_track_team_stat.rb', line 183

attribute :ufg_pct, Shale::Type::Float

#ufgaInteger

Returns uncontested field goals attempted

Examples:

stat.ufga #=> 35


175
# File 'lib/nba/box_score_player_track_team_stat.rb', line 175

attribute :ufga, Shale::Type::Integer

#ufgmInteger

Returns uncontested field goals made

Examples:

stat.ufgm #=> 24


167
# File 'lib/nba/box_score_player_track_team_stat.rb', line 167

attribute :ufgm, Shale::Type::Integer

Instance Method Details

#gameGame?

Returns the game object

Examples:

stat.game #=> #<NBA::Game>


225
226
227
# File 'lib/nba/box_score_player_track_team_stat.rb', line 225

def game
  Games.find(game_id)
end

#teamTeam?

Returns the team object

Examples:

stat.team #=> #<NBA::Team>


215
216
217
# File 'lib/nba/box_score_player_track_team_stat.rb', line 215

def team
  Teams.find(team_id)
end