mean_matrixT_mean_matrixMeanMatrixMeanMatrixmean_matrix (Operator)

Name

mean_matrixT_mean_matrixMeanMatrixMeanMatrixmean_matrix — Gibt den elementweisen Mittelwert einer Matrix zurück.

Signatur

mean_matrix( : : MatrixID, MeanType : MatrixMeanID)

Herror T_mean_matrix(const Htuple MatrixID, const Htuple MeanType, Htuple* MatrixMeanID)

void MeanMatrix(const HTuple& MatrixID, const HTuple& MeanType, HTuple* MatrixMeanID)

HMatrix HMatrix::MeanMatrix(const HString& MeanType) const

HMatrix HMatrix::MeanMatrix(const char* MeanType) const

HMatrix HMatrix::MeanMatrix(const wchar_t* MeanType) const   (Nur Windows)

static void HOperatorSet.MeanMatrix(HTuple matrixID, HTuple meanType, out HTuple matrixMeanID)

HMatrix HMatrix.MeanMatrix(string meanType)

def mean_matrix(matrix_id: HHandle, mean_type: str) -> HHandle

Beschreibung

Der Operator mean_matrixmean_matrixMeanMatrixMeanMatrixMeanMatrixmean_matrix gibt den Mittelwert der Elemente der Eingabematrix Matrix zurück. Die Eingabematrix ist durch das Matrix Handle MatrixIDMatrixIDMatrixIDMatrixIDmatrixIDmatrix_id definiert. Es wird eine neue Matrix MatrixMean mit dem Ergebnis generiert und das Matrix Handle MatrixMeanIDMatrixMeanIDMatrixMeanIDMatrixMeanIDmatrixMeanIDmatrix_mean_id dieser Matrix zurückgegeben. Zugriff auf die Elemente der Matrix ist z.B. mit dem Operator get_full_matrixget_full_matrixGetFullMatrixGetFullMatrixGetFullMatrixget_full_matrix möglich.

Die Art der Mittelwertbildung der Matrix kann mittels des Parameters MeanTypeMeanTypeMeanTypeMeanTypemeanTypemean_type gewählt werden:

'columns'"columns""columns""columns""columns""columns":

Die Mittelwertbildung erfolgt für jede Spalte der Matrix Matrix einzeln. Die Ergebnismatrix MatrixMean hat eine Zeile und die gleiche Anzahl an Spalten wie die Eingabematrix.

Beispiel:

MeanTypeMeanTypeMeanTypeMeanTypemeanTypemean_type = 'columns'"columns""columns""columns""columns""columns"

'rows'"rows""rows""rows""rows""rows":

Die Mittelwertbildung erfolgt für jede Zeile der Matrix Matrix einzeln. Die Ergebnismatrix MatrixMean hat die gleiche Anzahl an Zeilen wie die Eingabematrix und eine Spalte.

Beispiel:

MeanTypeMeanTypeMeanTypeMeanTypemeanTypemean_type = 'rows'"rows""rows""rows""rows""rows"

'full'"full""full""full""full""full":

Die Mittelwertbildung erfolgt über alle Elemente der Matrix Matrix. Die Ergebnismatrix MatrixMean hat eine Zeile und eine Spalte.

Beispiel:

MeanTypeMeanTypeMeanTypeMeanTypemeanTypemean_type = 'full'"full""full""full""full""full"

Ausführungsinformationen

Parameter

MatrixIDMatrixIDMatrixIDMatrixIDmatrixIDmatrix_id (input_control)  matrix HMatrix, HTupleHHandleHTupleHtuple (handle) (IntPtr) (HHandle) (handle)

Matrix Handle der Eingabematrix.

MeanTypeMeanTypeMeanTypeMeanTypemeanTypemean_type (input_control)  string HTuplestrHTupleHtuple (string) (string) (HString) (char*)

Art der Mittelwertwertbildung.

Defaultwert: 'columns' "columns" "columns" "columns" "columns" "columns"

Werteliste: 'columns'"columns""columns""columns""columns""columns", 'full'"full""full""full""full""full", 'rows'"rows""rows""rows""rows""rows"

MatrixMeanIDMatrixMeanIDMatrixMeanIDMatrixMeanIDmatrixMeanIDmatrix_mean_id (output_control)  matrix HMatrix, HTupleHHandleHTupleHtuple (handle) (IntPtr) (HHandle) (handle)

Matrix Handle mit den Mittelwerten der Eingabematrix.

Ergebnis

Sind die Parameterwerte korrekt, dann liefert mean_matrixmean_matrixMeanMatrixMeanMatrixMeanMatrixmean_matrix den Wert 2 (H_MSG_TRUE). Gegebenenfalls wird eine Fehlerbehandlung durchgeführt.

Vorgänger

create_matrixcreate_matrixCreateMatrixCreateMatrixCreateMatrixcreate_matrix

Nachfolger

get_full_matrixget_full_matrixGetFullMatrixGetFullMatrixGetFullMatrixget_full_matrix, get_value_matrixget_value_matrixGetValueMatrixGetValueMatrixGetValueMatrixget_value_matrix

Siehe auch

norm_matrixnorm_matrixNormMatrixNormMatrixNormMatrixnorm_matrix, sum_matrixsum_matrixSumMatrixSumMatrixSumMatrixsum_matrix

Modul

Foundation