code: public static void subvector(DMatrix1Row A, int rowA, int colA, int length , boolean row, int offsetV, DMatrix1Row v) {
          if( row ) {
              for( int i = 0; i < length; i++ ) {
                  v.set( offsetV +i , A.get(rowA,colA+i) );
              }
          } else {
              for( int i = 0; i < length; i++ ) {
                  v.set( offsetV +i , A.get(rowA+i,colA));
              }
          }
      }
docs: <p>
  Extracts a row or column vector from matrix A.  The first element in the matrix is at element (rowA,colA).
  The next 'length' elements are extracted along a row or column.  The results are put into vector 'v'
  start at its element v0.
  </p>
  
  @param A Matrix that the vector is being extracted from.  Not modified.
  @param rowA Row of the first element that is extracted.
  @param colA Column of the first element that is extracted.
  @param length Length of the extracted vector.
  @param row If true a row vector is extracted, otherwise a column vector is extracted.
  @param offsetV First element in 'v' where the results are extracted to.
  @param v Vector where the results are written to. Modified.