skcyto.HyperlogTransformer

class skcyto.HyperlogTransformer(t: float = 262144, m: float = 4.5, w: float = 0.5, a: float = 0)[source]

Hyperlog transform

Implemented according to GatingML2.0 specification.

See also

Bagwell CB. Hyperlog-a flexible log-like transform for negative, zero, and positive valued data. Cytometry A., 2005:64(1):34–42.

Parameters:
tfloat

Upper bound of the linear scale, by default 262144

mfloat

Number of decades for the logarithmic scale, by default 4.5

wfloat

Number of decades for linear scale, by default 0.5

afloat

Number of negative decades, by default 0

__init__(t: float = 262144, m: float = 4.5, w: float = 0.5, a: float = 0)[source]
fit(X: ndarray[Any, dtype[ScalarType]], y: ndarray[Any, dtype[ScalarType]] | None = None)[source]

Fit only validates parameters and data, as everything is defined by the user.

XNDArray

Input data

yIgnored.

Not used, only present for API conventions.

fit_transform(X: ndarray[Any, dtype[ScalarType]], y=None) ndarray[Any, dtype[ScalarType]][source]

Fit and transform data

As fit does not doo anything, this is identical to just running transform and is only implemented for API conventions.

Parameters:
XNDArray

Input data

yIgnored.

Not used, only present for API conventions.

Returns:
NDArray

Transformed data

inverse_transform(X: ndarray[Any, dtype[ScalarType]]) ndarray[Any, dtype[ScalarType]][source]

Perform inverse hyperlog transform

Parameters:
XNDArray

Input data

Returns:
NDArray

inversely transformed data

transform(X: ndarray[Any, dtype[ScalarType]]) ndarray[Any, dtype[ScalarType]][source]

Transform according to specified hyperlog

Parameters:
XNDArray

Data

Returns:
NDArray

Transformed data