I have been trying to get a working LightGBM model which I can train on my data, select the best performing model with highest f1 score and then use it obtain the f1 score on the testing data. However, all the material I have found online gives me errors.

Currently, what I am doing is after splitting the data and test set (70:30), and preparing cv folds, I prepare the recipe, then the tuning parameters etc., eventually examining the models for parameter selection using F1 scores.

I have data which I want to use to predict the loan_default status and whether someone will default or not, using 21 predictors in my data set, using downsampling.

Does anyone have a working script or helpful resources?

Thank you in advance.


1 Answer 1


I've found that there are usually a lot of full solution code notebooks available in Kaggle for these sorts of problems. Here's a couple I was able to find based on a quick Google search:

Hope this helps.

  • $\begingroup$ Your answer could be improved with additional supporting information. Please edit to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers in the help center. $\endgroup$
    – Community Bot
    Commented Jun 19, 2022 at 19:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.