TwoPieceLogNormalLSS#

class superglm.TwoPieceLogNormalLSS(
parametrisation: Literal['mean', 'location'] = 'mean',
scale_floor: float = 0.01,
skew_bound: float = 0.9,
)#

Bases: MeanPredictor, LocationPredictor, ScalePredictor, SkewPredictor

Two-piece log-normal with natural parameters (mean | location, scale, skew).

log Y = mu + sigma W with W epsilon-skew two-piece standard normal; the right piece is the wide one, so a positive skew predictor means a heavier right tail on the log scale. The default mean form puts E[Y] first under a log link, so its relativities multiply the mean.

Parameters:
parametrisation{“mean”, “location”}, default=”mean”

Choose family.mean(...) for the conditional response mean or family.location(...) for the location in the log-response law. Declare family.scale(...) and family.skew(...) in either form.

scale_floorfloat, default=0.01

Nonnegative lower bound on scale. Its default link is log(scale - scale_floor).

skew_boundfloat, default=0.9

Positive bound, less than one, on the magnitude of epsilon. The default bounded link keeps skew strictly inside these limits.

Notes

Fit the positive response directly. Location and scale are parameters of the two-piece log-response law; they need not be its mean and standard deviation. skew is epsilon, not the standardized third moment. predict returns the response mean in either parametrization.