fuzzyclust.models.HingeNode#

class fuzzyclust.models.HingeNode(theta, kind, depth, n_samples, sse, rmse, condition, node_id=0, left=None, right=None)[source]#

Bases: object

One node of a HingingHyperplaneTree.

Attributes:
thetandarray of shape (2, n_features + 1) or (1, n_features + 1)

The two hyperplanes \(\boldsymbol\theta_1,\boldsymbol\theta_2\) of the hinge (a single plane for a linear leaf).

kind{“max”, “min”, “linear”}

Hinge function \(\max\) / \(\min\) of the two planes, or a plain linear model.

depth, n_samples, sse, rmse, conditionnode statistics

condition is the hinge-identification quality \(\varrho\) (1 = the hinge split agrees perfectly with the fuzzy memberships).

left, rightHingeNode or None

Children; left receives the samples where plane 1 is active.

hinge_value(Xe)[source]#

Value of the node model for extended regressors Xe.

plane1_active(Xe)[source]#

Boolean mask of the samples on the side of the hinge where plane 1 is active.