ratings.setQuick(3, 3.0);
ratings.setQuick(5, 5.0);
Matrix riIiMaybeTransposed = AlternatingLeastSquaresSolver.createRiIiMaybeTransposed(ratings);
assertEquals(1, riIiMaybeTransposed.numCols(), 1);
assertEquals(3, riIiMaybeTransposed.numRows(), 3);
assertEquals(1.0, riIiMaybeTransposed.getQuick(0, 0), EPSILON);
assertEquals(3.0, riIiMaybeTransposed.getQuick(1, 0), EPSILON);
assertEquals(5.0, riIiMaybeTransposed.getQuick(2, 0), EPSILON);
}