Method: CsrMatrix::Helpers#max_row
- Defined in:
- lib/csrmatrix/helpers.rb
#max_row(array) ⇒ Object
max_col
30 31 32 33 34 35 36 37 38 39 40 |
# File 'lib/csrmatrix/helpers.rb', line 30 def max_row(array) # Identifies the 'row' value of an array (eg. the number of entries in a row) # pre array # post row count of array values = array max_count = 0 values.each_index do |i| max_count += 1 end return max_count end |