Skip to content

Releases: ottenbreit-data-science/aplr

Bugfix

12 Sep 21:18

Choose a tag to compare

Fixed a minor issue in the get_unique_term_affiliation_shape method that could cause crashes in rare cases.

Improved visualization of interactions

12 Sep 18:05

Choose a tag to compare

Changes

  • The get_unique_term_affiliation_shape method now includes an optional parameter, additional_points (default: 250). This parameter adds evenly spaced points for two-way or higher-order interactions, ensuring smoother visualization and reducing artifacts from sparse data. For the same reason, the default value for max_rows_before_sampling has been increased from 100,000 to 500,000.

  • The example scripts now use heatmaps instead of 3D charts to plot two-way interactions, improving clarity and interpretability.

Added a convenience method to APLRRegressor

02 Sep 20:28

Choose a tag to compare

remove_provided_custom_functions method added to APLRRegressor:

  • This method removes any custom functions provided for calculating the loss, negative gradient, or validation error.
  • Useful after model training with custom functions, ensuring that the APLRRegressor object no longer depends on these functions—so they do not need to be present in the Python environment when loading a saved model.

Smoothing and Mitigation of Boundary Problems by Regularization. Backwards Compatibility.

17 Apr 08:23

Choose a tag to compare

  • Added ridge_penalty Hyperparameter: Introduced a new hyperparameter, ridge_penalty (default is 0.0001), which specifies the (weighted) ridge penalty applied to the model. Positive values can smooth model effects and help mitigate boundary problems, such as regression coefficients with excessively high magnitudes near the boundaries. To find the optimal value, consider using a grid search or similar tuning methods. Negative values are treated as zero. The default value of 0.0001 has been determined based on empirical tests on more than a hundred datasets.

  • Changed Default Value for early_stopping_rounds: Updated the default value of the early_stopping_rounds hyperparameter from 500 to 200 to improve convergence speed.

  • Introduced Backwards Compatibility: Enabled backwards compatibility for already trained models. It is now possible to load models (e.g., using pickle or joblib) as long as they were trained with APLR version 10.6.1 or newer.

New Features: Specify Minimum Observations Per Split for Each Predictor & Python 3.13 Support

26 Nov 17:01

Choose a tag to compare

  • Specify Minimum Observations Per Split: Added the ability to set min_observations_in_split for individual predictors by passing the predictor_min_observations_in_split parameter to the fit method.
  • Python 3.13 Support: Introduced compatibility with Python 3.13.
  • PyPy Wheels Removed: Removed PyPy wheels due to a bug in setuptools that prevents using a newer version of cibuildwheel for building wheels.

Minor Bugfix: Early Stopping Issue

13 Nov 17:01

Choose a tag to compare

Fixed a bug that could, on rare occasions, cause premature early stopping when num_first_steps_with_linear_effects_only > 0 or boosting_steps_before_interactions_are_allowed > 0.

Bugfix: Negative Gradient Calculation for Group MSE Loss Functions

05 Nov 15:52

Choose a tag to compare

Fixed a bug in the calculation of the negative gradient for the group_mse and group_mse_cycle loss functions.

Enhanced Control Over Training Stages: Linear, Non-Linear, and Interaction Effects

02 Nov 08:30

Choose a tag to compare

This update improves the ability to sequentially train linear effects, then non-linear effects, and finally interaction effects. While the default hyperparameters do not follow this sequence, it can be enabled using the num_first_steps_with_linear_effects_only and boosting_steps_before_interactions_are_allowed parameters.

With this update, at each stage, the algorithm now selects the boosting step with the lowest validation error before progressing to the next stage. This enhancement helps prevent overfitting and allows for a fully fitted linear model before moving on to non-linear and interaction effects. This approach can improve interpretability, as linear effects are typically easier to understand than non-linear effects, and interactions are often the most complex to interpret.

Minor bugfix: set_intercept method

29 Oct 20:01

Choose a tag to compare

This release includes a minor bugfix for the set_intercept method. The method now ensures that get_term_coefficients returns the updated intercept, reflecting any adjustments made.

New Feature: Adjust Intercept After Model Fitting

29 Oct 19:07

Choose a tag to compare

The new set_intercept method in APLRRegressor enables users to manually adjust the model intercept after fitting, which is useful for calibration purposes. The API reference has been updated accordingly, and the README has been rewritten for clarity, with contact details added.