static public ShoMatrix Standardize <TMatrix>(this TMatrix matrix, int maxMatrixVal, ParallelOptions parallelOptions) where TMatrix : Matrix <string, string, double> { if (matrix.RowCount > 0) { ShoMatrix snpMatrixNew = EigenstratMain.StandardizeGToCreateX <ShoMatrix>(maxMatrixVal, matrix, ShoMatrix.CreateDefaultInstance, parallelOptions); return(snpMatrixNew); } else { return(new ShoMatrix(matrix)); } }
static public ShoMatrix Standardize(this ShoMatrix shoMatrix, int maxMatrixVal, ParallelOptions parallelOptions, bool onlyMeanCenter) { ShoMatrix snpMatrixNew = EigenstratMain.StandardizeGToCreateX <ShoMatrix>(maxMatrixVal, shoMatrix, ShoMatrix.CreateDefaultInstance, parallelOptions, onlyMeanCenter); return(snpMatrixNew); }
static public TMatrix Standardize <TMatrix>(this TMatrix matrix, int maxMatrixVal, MatrixFactoryDelegate <TMatrix, string, string, double> zeroMatrixFractory, ParallelOptions parallelOptions) where TMatrix : Matrix <string, string, double> { TMatrix snpMatrixNew = EigenstratMain.StandardizeGToCreateX(maxMatrixVal, matrix, zeroMatrixFractory, parallelOptions); return(snpMatrixNew); }