code: function R_I(A) {
        A = jStat.copy(A);
        var size = A.length;
        var I = jStat.identity(size);
        jStat.arange(size - 1, -1, -1).forEach(function(i) {
          jStat.sliceAssign(
              I, { row: i }, jStat.divide(jStat.slice(I, { row: i }), A[i][i]));
          jStat.sliceAssign(
              A, { row: i }, jStat.divide(jStat.slice(A, { row: i }), A[i][i]));
          jStat.arange(i).forEach(function(j) {
            var c = jStat.multiply(A[j][i], -1);
            var Aj = jStat.slice(A, { row: j });
            var cAi = jStat.multiply(jStat.slice(A, { row: i }), c);
            jStat.sliceAssign(A, { row: j }, jStat.add(Aj, cAi));
            var Ij = jStat.slice(I, { row: j });
            var cIi = jStat.multiply(jStat.slice(I, { row: i }), c);
            jStat.sliceAssign(I, { row: j }, jStat.add(Ij, cIi));
          })
        });
        return I;
      }
docs: solve least squard problem for Ax=b as QR decomposition way if b is [[b1],[b2],[b3]] form will return [[x1],[x2],[x3]] array form solution else b is [b1,b2,b3] form will return [x1,x2,x3] array form solution