if (column > 0) {
throw new MathIllegalStateException(LocalizedFormats.FIRST_COLUMNS_NOT_INITIALIZED_YET, column);
}
final int nRows = subMatrix.length;
if (nRows == 0) {
throw new NoDataException(LocalizedFormats.AT_LEAST_ONE_ROW);
}
final int nCols = subMatrix[0].length;
if (nCols == 0) {
throw new NoDataException(LocalizedFormats.AT_LEAST_ONE_COLUMN);
}
data = MathArrays.buildArray(getField(), subMatrix.length, nCols);
for (int i = 0; i < data.length; ++i) {
if (subMatrix[i].length != nCols) {
throw new DimensionMismatchException(nCols, subMatrix[i].length);