Method: Stick::Matrix#row2matrix

Defined in:
lib/stick/matrix.rb

#row2matrix(r) ⇒ Object

Returns the row/s of matrix as a Matrix



577
578
579
580
581
582
583
584
# File 'lib/stick/matrix.rb', line 577

def row2matrix(r)
  a = self.send(:row, r).to_a
  if r.is_a?(Range) and r.entries.size > 1
    return Matrix[*a]
  else
    return Matrix[a]
  end
end