Method: FinModeling::CalculationHeader#print
- Defined in:
- lib/finmodeling/calculation_summary.rb
#print(key_width = 18, max_decimals = 4, val_width = 12) ⇒ Object
70 71 72 73 74 75 76 77 78 79 |
# File 'lib/finmodeling/calculation_summary.rb', line 70 def print(key_width=18, max_decimals=4, val_width=12) justified_key = @key.fixed_width_left_justify(key_width) justified_vals = "" @vals.each do |val| justified_vals += " " + val.fixed_width_right_justify(val_width) end puts "\t" + justified_key + justified_vals end |