Class: MLB::BoxscorePitchingStats

Inherits:
Shale::Mapper
  • Object
show all
Defined in:
lib/mlb/boxscore_team_stats.rb

Overview

Represents pitching statistics for a team in a boxscore

Instance Attribute Summary collapse

Instance Attribute Details

#base_on_ballsInteger

Returns walks

Examples:

stats.base_on_balls #=> 3

Returns:

  • (Integer)

    the walks



157
# File 'lib/mlb/boxscore_team_stats.rb', line 157

attribute :base_on_balls, Shale::Type::Integer

#earned_runsInteger

Returns earned runs allowed

Examples:

stats.earned_runs #=> 4

Returns:

  • (Integer)

    the earned runs



125
# File 'lib/mlb/boxscore_team_stats.rb', line 125

attribute :earned_runs, Shale::Type::Integer

#eraString

Returns the earned run average

Examples:

stats.era #=> "3.84"

Returns:

  • (String)

    the ERA



173
# File 'lib/mlb/boxscore_team_stats.rb', line 173

attribute :era, Shale::Type::String

#hitsInteger

Returns hits allowed

Examples:

stats.hits #=> 7

Returns:

  • (Integer)

    the hits



133
# File 'lib/mlb/boxscore_team_stats.rb', line 133

attribute :hits, Shale::Type::Integer

#home_runsInteger

Returns home runs allowed

Examples:

stats.home_runs #=> 3

Returns:

  • (Integer)

    the home runs



141
# File 'lib/mlb/boxscore_team_stats.rb', line 141

attribute :home_runs, Shale::Type::Integer

#innings_pitchedString

Returns innings pitched

Examples:

stats.innings_pitched #=> "9.0"

Returns:

  • (String)

    the innings pitched



165
# File 'lib/mlb/boxscore_team_stats.rb', line 165

attribute :innings_pitched, Shale::Type::String

#runsInteger

Returns runs allowed

Examples:

stats.runs #=> 4

Returns:

  • (Integer)

    the runs



117
# File 'lib/mlb/boxscore_team_stats.rb', line 117

attribute :runs, Shale::Type::Integer

#strike_outsInteger

Returns strikeouts

Examples:

stats.strike_outs #=> 6

Returns:

  • (Integer)

    the strikeouts



149
# File 'lib/mlb/boxscore_team_stats.rb', line 149

attribute :strike_outs, Shale::Type::Integer