Skip to content

Commit 7eed65c

Browse files
renamed predictor to term where appropriate
1 parent 385b2fc commit 7eed65c

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

examples/train_aplr_cross_validation.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,11 +44,11 @@
4444
validation_error_per_boosting_step = best_model.get_validation_error_steps()
4545

4646
#Terms in the best model
47-
terms=pd.DataFrame({"Predictor":best_model.get_term_names(),"Coefficient":best_model.get_term_coefficients()})
47+
terms=pd.DataFrame({"term":best_model.get_term_names(),"coefficient":best_model.get_term_coefficients()})
4848

49-
#Coefficients for intercept and the first predictor per boosting step
49+
#Coefficients for intercept and the first term per boosting step
5050
intercept_coefficient_per_boosting_step = best_model.get_intercept_steps()
51-
first_predictor_coefficient_per_boosting_step = best_model.get_term_coefficient_steps(term_index=0)
51+
first_term_coefficient_per_boosting_step = best_model.get_term_coefficient_steps(term_index=0)
5252

5353
#Estimated feature importance was estimated on the validation set when the best model was trained
5454
estimated_feature_importance = pd.DataFrame({"predictor":predictors,"importance":best_model.get_feature_importance()})

examples/train_aplr_validation.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,11 @@
5454
validation_error_per_boosting_step = best_model.get_validation_error_steps()
5555

5656
#Terms in the best model
57-
terms=pd.DataFrame({"Predictor":best_model.get_term_names(),"Coefficient":best_model.get_term_coefficients()})
57+
terms=pd.DataFrame({"term":best_model.get_term_names(),"coefficient":best_model.get_term_coefficients()})
5858

59-
#Coefficients for intercept and the first predictor per boosting step
59+
#Coefficients for intercept and the first term per boosting step
6060
intercept_coefficient_per_boosting_step = best_model.get_intercept_steps()
61-
first_predictor_coefficient_per_boosting_step = best_model.get_term_coefficient_steps(term_index=0)
61+
first_term_coefficient_per_boosting_step = best_model.get_term_coefficient_steps(term_index=0)
6262

6363
#Estimated feature importance was estimated on the validation set when the best model was trained
6464
estimated_feature_importance = pd.DataFrame({"predictor":predictors,"importance":best_model.get_feature_importance()})

0 commit comments

Comments
 (0)