XGBoost Installation

classic Classic list List threaded Threaded
17 messages Options
Reply | Threaded
Open this post in threaded view
|

XGBoost Installation

xgboost
Dear All,

I have a mac with the latest version of R and python installed. I am using WEKA for an assignment and need to use XGBoost.
I have tried downloading the unofficial version as a package however that does not work.
I then tried the R Plugin version downloading RPlugin and pasting this in the command line in WEKA:
export R_HOME=/Library/Frameworks/R.framework/Resources
java -Xss10M -Xmx4096M -cp .:weka.jar weka.gui.GUIChoose

This however did not work either and R does not run.

If anyone has a very specific step-by-step guide to getting XGBoost on macOS please let me know!

Kind regards,
PYB
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
Reply | Threaded
Open this post in threaded view
|

Re: XGBoost Installation

Eibe Frank-2
Administrator
Which unofficial version do you mean? Both, RPlugin and wekaPython, are official packages, and both enable you to use XGBoost. With the RPlugin, you need to use XGBoost through the MLRClassifier and select XGBoost as the base learner (the first time you select this base learner, it will try to install it in R, which may take a while). Similarly, with wekaPython, you also need to use the corresponding ScikitLearnClassifier in WEKA with XGBoost as the base learner (and you need to have XGBoost installed in your relevant Python environment, which you may need to do manually).

The easiest way to use XGBoost in WEKA is probably through the RPlugin because the only manual work you (normally) need to do is to install R.

There might be an unofficial WEKA package for XGBoost out there, but it may not be maintained.

Cheers,
Eibe


On Fri, Jun 4, 2021 at 4:49 PM <[hidden email]> wrote:
Dear All,

I have a mac with the latest version of R and python installed. I am using WEKA for an assignment and need to use XGBoost.
I have tried downloading the unofficial version as a package however that does not work.
I then tried the R Plugin version downloading RPlugin and pasting this in the command line in WEKA:
export R_HOME=/Library/Frameworks/R.framework/Resources
java -Xss10M -Xmx4096M -cp .:weka.jar weka.gui.GUIChoose

This however did not work either and R does not run.

If anyone has a very specific step-by-step guide to getting XGBoost on macOS please let me know!

Kind regards,
PYB
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
Reply | Threaded
Open this post in threaded view
|

Re: XGBoost Installation

xgboost
https://github.com/SigDelta/weka-xgboost/releases - This is the link I used to download xgboost.
Using this downloaded I installed xgboost as an unofficial package in tools. It then comes under trees however does not run.

With the RPlugin the MLR classifier is unavailable to use. I have downloaded a new version of R and within R I also downloaded the MLR package. This still however does not run.
I have installed rJava within R as well.

On 04 Jun,2021, at 11:07, Eibe Frank <[hidden email]> wrote:

Which unofficial version do you mean? Both, RPlugin and wekaPython, are official packages, and both enable you to use XGBoost. With the RPlugin, you need to use XGBoost through the MLRClassifier and select XGBoost as the base learner (the first time you select this base learner, it will try to install it in R, which may take a while). Similarly, with wekaPython, you also need to use the corresponding ScikitLearnClassifier in WEKA with XGBoost as the base learner (and you need to have XGBoost installed in your relevant Python environment, which you may need to do manually).

The easiest way to use XGBoost in WEKA is probably through the RPlugin because the only manual work you (normally) need to do is to install R.

There might be an unofficial WEKA package for XGBoost out there, but it may not be maintained.

Cheers,
Eibe


On Fri, Jun 4, 2021 at 4:49 PM <[hidden email]> wrote:
Dear All,

I have a mac with the latest version of R and python installed. I am using WEKA for an assignment and need to use XGBoost.
I have tried downloading the unofficial version as a package however that does not work.
I then tried the R Plugin version downloading RPlugin and pasting this in the command line in WEKA:
export R_HOME=/Library/Frameworks/R.framework/Resources
java -Xss10M -Xmx4096M -cp .:weka.jar weka.gui.GUIChoose

This however did not work either and R does not run.

If anyone has a very specific step-by-step guide to getting XGBoost on macOS please let me know!

Kind regards,
PYB
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html


_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
Reply | Threaded
Open this post in threaded view
|

Re: XGBoost Installation

Eibe Frank-3
CONTENTS DELETED
The author has deleted this message.
Reply | Threaded
Open this post in threaded view
|

Re: XGBoost Installation

xgboost
Yes, I have followed this guide: https://riptutorial.com/weka/topic/7916/how-to-use-r-in-weka
I pasted this in the command line in WEKA: export R_HOME=/Library/Frameworks/R.framework/Resources
java -Xss10M -Xmx4096M -cp .:weka.jar weka.gui.GUIChooser

And this is the error from weka:

Kind regards,
Prakash



On 04 Jun,2021, at 13:52, Eibe Frank <[hidden email]> wrote:

Are you still running WEKA with R_HOME set to some value? It is normally best to let WEKA set the value of R_HOME itself.

If there are any error messages shown in the terminal from which you run WEKA, it would be useful to share those.

Cheers,
Eibe

On Fri, Jun 4, 2021 at 11:43 PM Prakash Bhagat <[hidden email]> wrote:
https://github.com/SigDelta/weka-xgboost/releases - This is the link I used to download xgboost.
Using this downloaded I installed xgboost as an unofficial package in tools. It then comes under trees however does not run.

With the RPlugin the MLR classifier is unavailable to use. I have downloaded a new version of R and within R I also downloaded the MLR package. This still however does not run.
I have installed rJava within R as well.
<Screenshot 2021-06-04 at 11.51.31.png>
On 04 Jun,2021, at 11:07, Eibe Frank <[hidden email]> wrote:

Which unofficial version do you mean? Both, RPlugin and wekaPython, are official packages, and both enable you to use XGBoost. With the RPlugin, you need to use XGBoost through the MLRClassifier and select XGBoost as the base learner (the first time you select this base learner, it will try to install it in R, which may take a while). Similarly, with wekaPython, you also need to use the corresponding ScikitLearnClassifier in WEKA with XGBoost as the base learner (and you need to have XGBoost installed in your relevant Python environment, which you may need to do manually).

The easiest way to use XGBoost in WEKA is probably through the RPlugin because the only manual work you (normally) need to do is to install R.

There might be an unofficial WEKA package for XGBoost out there, but it may not be maintained.

Cheers,
Eibe


On Fri, Jun 4, 2021 at 4:49 PM <[hidden email]> wrote:
Dear All,

I have a mac with the latest version of R and python installed. I am using WEKA for an assignment and need to use XGBoost.
I have tried downloading the unofficial version as a package however that does not work.
I then tried the R Plugin version downloading RPlugin and pasting this in the command line in WEKA:
export R_HOME=/Library/Frameworks/R.framework/Resources
java -Xss10M -Xmx4096M -cp .:weka.jar weka.gui.GUIChoose

This however did not work either and R does not run.

If anyone has a very specific step-by-step guide to getting XGBoost on macOS please let me know!

Kind regards,
PYB
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html


_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
Reply | Threaded
Open this post in threaded view
|

Re: XGBoost Installation

Eibe Frank-2
Administrator
You cannot set environment variables, etc., in WEKA's built-in CLI, which is really quite primitive and only pretends to be a proper OS terminal! You need to run the command in the macOS terminal. However, as I said, you should not set R_HOME explicitly unless you have installed R in a non-standard location. WEKA's RPlugin will find R on the Mac if it is installed in the standard place.

Cheers,
Eibe

On Sat, Jun 5, 2021 at 1:43 PM Prakash Bhagat <[hidden email]> wrote:
Yes, I have followed this guide: https://riptutorial.com/weka/topic/7916/how-to-use-r-in-weka
I pasted this in the command line in WEKA: export R_HOME=/Library/Frameworks/R.framework/Resources
java -Xss10M -Xmx4096M -cp .:weka.jar weka.gui.GUIChooser

And this is the error from weka:

Kind regards,
Prakash



On 04 Jun,2021, at 13:52, Eibe Frank <[hidden email]> wrote:

Are you still running WEKA with R_HOME set to some value? It is normally best to let WEKA set the value of R_HOME itself.

If there are any error messages shown in the terminal from which you run WEKA, it would be useful to share those.

Cheers,
Eibe

On Fri, Jun 4, 2021 at 11:43 PM Prakash Bhagat <[hidden email]> wrote:
https://github.com/SigDelta/weka-xgboost/releases - This is the link I used to download xgboost.
Using this downloaded I installed xgboost as an unofficial package in tools. It then comes under trees however does not run.

With the RPlugin the MLR classifier is unavailable to use. I have downloaded a new version of R and within R I also downloaded the MLR package. This still however does not run.
I have installed rJava within R as well.
<Screenshot 2021-06-04 at 11.51.31.png>
On 04 Jun,2021, at 11:07, Eibe Frank <[hidden email]> wrote:

Which unofficial version do you mean? Both, RPlugin and wekaPython, are official packages, and both enable you to use XGBoost. With the RPlugin, you need to use XGBoost through the MLRClassifier and select XGBoost as the base learner (the first time you select this base learner, it will try to install it in R, which may take a while). Similarly, with wekaPython, you also need to use the corresponding ScikitLearnClassifier in WEKA with XGBoost as the base learner (and you need to have XGBoost installed in your relevant Python environment, which you may need to do manually).

The easiest way to use XGBoost in WEKA is probably through the RPlugin because the only manual work you (normally) need to do is to install R.

There might be an unofficial WEKA package for XGBoost out there, but it may not be maintained.

Cheers,
Eibe


On Fri, Jun 4, 2021 at 4:49 PM <[hidden email]> wrote:
Dear All,

I have a mac with the latest version of R and python installed. I am using WEKA for an assignment and need to use XGBoost.
I have tried downloading the unofficial version as a package however that does not work.
I then tried the R Plugin version downloading RPlugin and pasting this in the command line in WEKA:
export R_HOME=/Library/Frameworks/R.framework/Resources
java -Xss10M -Xmx4096M -cp .:weka.jar weka.gui.GUIChoose

This however did not work either and R does not run.

If anyone has a very specific step-by-step guide to getting XGBoost on macOS please let me know!

Kind regards,
PYB
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
Reply | Threaded
Open this post in threaded view
|

Re: XGBoost Installation

xgboost
Thanks very much,

I have managed to get windows access and followed the tutorial on youtube for downloading the rplugin. I am using xgboost as a classification method and comparing it to random forests. Random forest gives an accuracy of 75% whereas XGBoost gives an accuracy of only 52%. I was wondering if you could help me as i may have made some errors when implementing xgboost. 
I have attached the data used. I filled in missing values for revol_util and converted nominal features to binary when using xgboost. 
I then used the costsensitiveclassifier with a 5 to 1 cost for false positives and used 5 fold cross-validation. Following this, I used mlrclassifier and used classif.xgboost under Rlearner.
I will do hyper parameter tuning after but was wandering if i had made a mistake with xgboost as the accuracy is so low.
Any help would be much appreciated!

Kind regards,
Prakash

On Sat, Jun 5, 2021 at 4:16 AM Eibe Frank <[hidden email]> wrote:
You cannot set environment variables, etc., in WEKA's built-in CLI, which is really quite primitive and only pretends to be a proper OS terminal! You need to run the command in the macOS terminal. However, as I said, you should not set R_HOME explicitly unless you have installed R in a non-standard location. WEKA's RPlugin will find R on the Mac if it is installed in the standard place.

Cheers,
Eibe

On Sat, Jun 5, 2021 at 1:43 PM Prakash Bhagat <[hidden email]> wrote:
Yes, I have followed this guide: https://riptutorial.com/weka/topic/7916/how-to-use-r-in-weka
I pasted this in the command line in WEKA: export R_HOME=/Library/Frameworks/R.framework/Resources
java -Xss10M -Xmx4096M -cp .:weka.jar weka.gui.GUIChooser

And this is the error from weka:

Kind regards,
Prakash



On 04 Jun,2021, at 13:52, Eibe Frank <[hidden email]> wrote:

Are you still running WEKA with R_HOME set to some value? It is normally best to let WEKA set the value of R_HOME itself.

If there are any error messages shown in the terminal from which you run WEKA, it would be useful to share those.

Cheers,
Eibe

On Fri, Jun 4, 2021 at 11:43 PM Prakash Bhagat <[hidden email]> wrote:
https://github.com/SigDelta/weka-xgboost/releases - This is the link I used to download xgboost.
Using this downloaded I installed xgboost as an unofficial package in tools. It then comes under trees however does not run.

With the RPlugin the MLR classifier is unavailable to use. I have downloaded a new version of R and within R I also downloaded the MLR package. This still however does not run.
I have installed rJava within R as well.
<Screenshot 2021-06-04 at 11.51.31.png>
On 04 Jun,2021, at 11:07, Eibe Frank <[hidden email]> wrote:

Which unofficial version do you mean? Both, RPlugin and wekaPython, are official packages, and both enable you to use XGBoost. With the RPlugin, you need to use XGBoost through the MLRClassifier and select XGBoost as the base learner (the first time you select this base learner, it will try to install it in R, which may take a while). Similarly, with wekaPython, you also need to use the corresponding ScikitLearnClassifier in WEKA with XGBoost as the base learner (and you need to have XGBoost installed in your relevant Python environment, which you may need to do manually).

The easiest way to use XGBoost in WEKA is probably through the RPlugin because the only manual work you (normally) need to do is to install R.

There might be an unofficial WEKA package for XGBoost out there, but it may not be maintained.

Cheers,
Eibe


On Fri, Jun 4, 2021 at 4:49 PM <[hidden email]> wrote:
Dear All,

I have a mac with the latest version of R and python installed. I am using WEKA for an assignment and need to use XGBoost.
I have tried downloading the unofficial version as a package however that does not work.
I then tried the R Plugin version downloading RPlugin and pasting this in the command line in WEKA:
export R_HOME=/Library/Frameworks/R.framework/Resources
java -Xss10M -Xmx4096M -cp .:weka.jar weka.gui.GUIChoose

This however did not work either and R does not run.

If anyone has a very specific step-by-step guide to getting XGBoost on macOS please let me know!

Kind regards,
PYB
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

LCClean_Numeric.csv (10M) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: XGBoost Installation

Eibe Frank
CONTENTS DELETED
The author has deleted this message.
Reply | Threaded
Open this post in threaded view
|

Re: XGBoost Installation

xgboost
Thanks so much for this!
For your first point, how do I set a minimum number of boosting iterations?
I have looked within the MLR classifier setting however see no option for min iterations.
If I use a cost matrix in the classifier then under more options for test I should create the same confusion matrix, correct?

Kind regards,
Prakash

On Sat, Jun 5, 2021 at 12:56 PM Eibe Frank <[hidden email]> wrote:
The default number of iterations used by XGBoost when applied through the RPlugin is 1. You definitely need to increase the number of boosting iterations. I would also switch the CostSensitiveClassifier to use the minimum-expected cost approach, not the default approach based on reweighting the training data.

Of course, you should also specify the same cost matrix for evaluation under "More options..." in the Classify tab.

The following configuration worked well in a quick try on the sonar data from the UCI repository:

weka.classifiers.meta.CostSensitiveClassifier -cost-matrix "[0.0 5.0; 1.0 0.0]" -M  -W weka.classifiers.mlr.MLRClassifier -- -learner classif.xgboost -params nrounds=100,max_depth=3,subsample=0.5,colsample_bynode=0.5

You can right-click on the text field containing the classifier configuration in the Classify panel and paste the above configuration into the Explorer (assuming you have a dataset with only two classes, it should work).

The reason for using the minimum-expected cost mode of the CostSensitiveClassifier is that it does not change the training data. The default mode of the CostSensitiveClassifier uses instance weights in the training data to reflect costs. I don't know how well that works in conjunction with MLRClassifier.

Cheers,
Eibe

On Sat, Jun 5, 2021 at 11:33 PM Prakash Bhagat <[hidden email]> wrote:
Thanks very much,

I have managed to get windows access and followed the tutorial on youtube for downloading the rplugin. I am using xgboost as a classification method and comparing it to random forests. Random forest gives an accuracy of 75% whereas XGBoost gives an accuracy of only 52%. I was wondering if you could help me as i may have made some errors when implementing xgboost. 
I have attached the data used. I filled in missing values for revol_util and converted nominal features to binary when using xgboost. 
I then used the costsensitiveclassifier with a 5 to 1 cost for false positives and used 5 fold cross-validation. Following this, I used mlrclassifier and used classif.xgboost under Rlearner.
I will do hyper parameter tuning after but was wandering if i had made a mistake with xgboost as the accuracy is so low.
Any help would be much appreciated!

Kind regards,
Prakash

On Sat, Jun 5, 2021 at 4:16 AM Eibe Frank <[hidden email]> wrote:
You cannot set environment variables, etc., in WEKA's built-in CLI, which is really quite primitive and only pretends to be a proper OS terminal! You need to run the command in the macOS terminal. However, as I said, you should not set R_HOME explicitly unless you have installed R in a non-standard location. WEKA's RPlugin will find R on the Mac if it is installed in the standard place.

Cheers,
Eibe

On Sat, Jun 5, 2021 at 1:43 PM Prakash Bhagat <[hidden email]> wrote:
Yes, I have followed this guide: https://riptutorial.com/weka/topic/7916/how-to-use-r-in-weka
I pasted this in the command line in WEKA: export R_HOME=/Library/Frameworks/R.framework/Resources
java -Xss10M -Xmx4096M -cp .:weka.jar weka.gui.GUIChooser

And this is the error from weka:

Kind regards,
Prakash



On 04 Jun,2021, at 13:52, Eibe Frank <[hidden email]> wrote:

Are you still running WEKA with R_HOME set to some value? It is normally best to let WEKA set the value of R_HOME itself.

If there are any error messages shown in the terminal from which you run WEKA, it would be useful to share those.

Cheers,
Eibe

On Fri, Jun 4, 2021 at 11:43 PM Prakash Bhagat <[hidden email]> wrote:
https://github.com/SigDelta/weka-xgboost/releases - This is the link I used to download xgboost.
Using this downloaded I installed xgboost as an unofficial package in tools. It then comes under trees however does not run.

With the RPlugin the MLR classifier is unavailable to use. I have downloaded a new version of R and within R I also downloaded the MLR package. This still however does not run.
I have installed rJava within R as well.
<Screenshot 2021-06-04 at 11.51.31.png>
On 04 Jun,2021, at 11:07, Eibe Frank <[hidden email]> wrote:

Which unofficial version do you mean? Both, RPlugin and wekaPython, are official packages, and both enable you to use XGBoost. With the RPlugin, you need to use XGBoost through the MLRClassifier and select XGBoost as the base learner (the first time you select this base learner, it will try to install it in R, which may take a while). Similarly, with wekaPython, you also need to use the corresponding ScikitLearnClassifier in WEKA with XGBoost as the base learner (and you need to have XGBoost installed in your relevant Python environment, which you may need to do manually).

The easiest way to use XGBoost in WEKA is probably through the RPlugin because the only manual work you (normally) need to do is to install R.

There might be an unofficial WEKA package for XGBoost out there, but it may not be maintained.

Cheers,
Eibe


On Fri, Jun 4, 2021 at 4:49 PM <[hidden email]> wrote:
Dear All,

I have a mac with the latest version of R and python installed. I am using WEKA for an assignment and need to use XGBoost.
I have tried downloading the unofficial version as a package however that does not work.
I then tried the R Plugin version downloading RPlugin and pasting this in the command line in WEKA:
export R_HOME=/Library/Frameworks/R.framework/Resources
java -Xss10M -Xmx4096M -cp .:weka.jar weka.gui.GUIChoose

This however did not work either and R does not run.

If anyone has a very specific step-by-step guide to getting XGBoost on macOS please let me know!

Kind regards,
PYB
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
Reply | Threaded
Open this post in threaded view
|

Re: XGBoost Installation

Eibe Frank-3
CONTENTS DELETED
The author has deleted this message.
Reply | Threaded
Open this post in threaded view
|

Re: XGBoost Installation

xgboost
Thanks, 
I did so however in my problem the cost of a False Positive is 5 times more than a False Negative thus the confusion matrix used is [0.0 1.0; 5.0 0.0]. When implementing the setting you suggested I get an accuracy of 57% still relatively low. 
The highest I was able to get was 67% when using nrounds=1000.
Could it just be that XGBoost does not work as well as knn and rf for this case or am I missing something?

Kind regards,
Prakash

On Sun, Jun 6, 2021 at 2:13 AM Eibe Frank <[hidden email]> wrote:
Looking at the configuration string I posted, you will see

-learner classif.xgboost -params nrounds=100,max_depth=3,subsample=0.5,colsample_bynode=0.5

The

-params

flag introduces the parameters that will be used for the MLR learner that is specified. You need to paste those into the corresponding text field in the GenericObjectEditor when you configure MLRClassifier.

Yes, you should use the same cost matrix.

Cheers,
Eibe

On Sun, Jun 6, 2021 at 1:09 PM Prakash Bhagat <[hidden email]> wrote:
Thanks so much for this!
For your first point, how do I set a minimum number of boosting iterations?
I have looked within the MLR classifier setting however see no option for min iterations.
If I use a cost matrix in the classifier then under more options for test I should create the same confusion matrix, correct?

Kind regards,
Prakash

On Sat, Jun 5, 2021 at 12:56 PM Eibe Frank <[hidden email]> wrote:
The default number of iterations used by XGBoost when applied through the RPlugin is 1. You definitely need to increase the number of boosting iterations. I would also switch the CostSensitiveClassifier to use the minimum-expected cost approach, not the default approach based on reweighting the training data.

Of course, you should also specify the same cost matrix for evaluation under "More options..." in the Classify tab.

The following configuration worked well in a quick try on the sonar data from the UCI repository:

weka.classifiers.meta.CostSensitiveClassifier -cost-matrix "[0.0 5.0; 1.0 0.0]" -M  -W weka.classifiers.mlr.MLRClassifier -- -learner classif.xgboost -params nrounds=100,max_depth=3,subsample=0.5,colsample_bynode=0.5

You can right-click on the text field containing the classifier configuration in the Classify panel and paste the above configuration into the Explorer (assuming you have a dataset with only two classes, it should work).

The reason for using the minimum-expected cost mode of the CostSensitiveClassifier is that it does not change the training data. The default mode of the CostSensitiveClassifier uses instance weights in the training data to reflect costs. I don't know how well that works in conjunction with MLRClassifier.

Cheers,
Eibe

On Sat, Jun 5, 2021 at 11:33 PM Prakash Bhagat <[hidden email]> wrote:
Thanks very much,

I have managed to get windows access and followed the tutorial on youtube for downloading the rplugin. I am using xgboost as a classification method and comparing it to random forests. Random forest gives an accuracy of 75% whereas XGBoost gives an accuracy of only 52%. I was wondering if you could help me as i may have made some errors when implementing xgboost. 
I have attached the data used. I filled in missing values for revol_util and converted nominal features to binary when using xgboost. 
I then used the costsensitiveclassifier with a 5 to 1 cost for false positives and used 5 fold cross-validation. Following this, I used mlrclassifier and used classif.xgboost under Rlearner.
I will do hyper parameter tuning after but was wandering if i had made a mistake with xgboost as the accuracy is so low.
Any help would be much appreciated!

Kind regards,
Prakash

On Sat, Jun 5, 2021 at 4:16 AM Eibe Frank <[hidden email]> wrote:
You cannot set environment variables, etc., in WEKA's built-in CLI, which is really quite primitive and only pretends to be a proper OS terminal! You need to run the command in the macOS terminal. However, as I said, you should not set R_HOME explicitly unless you have installed R in a non-standard location. WEKA's RPlugin will find R on the Mac if it is installed in the standard place.

Cheers,
Eibe

On Sat, Jun 5, 2021 at 1:43 PM Prakash Bhagat <[hidden email]> wrote:
Yes, I have followed this guide: https://riptutorial.com/weka/topic/7916/how-to-use-r-in-weka
I pasted this in the command line in WEKA: export R_HOME=/Library/Frameworks/R.framework/Resources
java -Xss10M -Xmx4096M -cp .:weka.jar weka.gui.GUIChooser

And this is the error from weka:

Kind regards,
Prakash



On 04 Jun,2021, at 13:52, Eibe Frank <[hidden email]> wrote:

Are you still running WEKA with R_HOME set to some value? It is normally best to let WEKA set the value of R_HOME itself.

If there are any error messages shown in the terminal from which you run WEKA, it would be useful to share those.

Cheers,
Eibe

On Fri, Jun 4, 2021 at 11:43 PM Prakash Bhagat <[hidden email]> wrote:
https://github.com/SigDelta/weka-xgboost/releases - This is the link I used to download xgboost.
Using this downloaded I installed xgboost as an unofficial package in tools. It then comes under trees however does not run.

With the RPlugin the MLR classifier is unavailable to use. I have downloaded a new version of R and within R I also downloaded the MLR package. This still however does not run.
I have installed rJava within R as well.
<Screenshot 2021-06-04 at 11.51.31.png>
On 04 Jun,2021, at 11:07, Eibe Frank <[hidden email]> wrote:

Which unofficial version do you mean? Both, RPlugin and wekaPython, are official packages, and both enable you to use XGBoost. With the RPlugin, you need to use XGBoost through the MLRClassifier and select XGBoost as the base learner (the first time you select this base learner, it will try to install it in R, which may take a while). Similarly, with wekaPython, you also need to use the corresponding ScikitLearnClassifier in WEKA with XGBoost as the base learner (and you need to have XGBoost installed in your relevant Python environment, which you may need to do manually).

The easiest way to use XGBoost in WEKA is probably through the RPlugin because the only manual work you (normally) need to do is to install R.

There might be an unofficial WEKA package for XGBoost out there, but it may not be maintained.

Cheers,
Eibe


On Fri, Jun 4, 2021 at 4:49 PM <[hidden email]> wrote:
Dear All,

I have a mac with the latest version of R and python installed. I am using WEKA for an assignment and need to use XGBoost.
I have tried downloading the unofficial version as a package however that does not work.
I then tried the R Plugin version downloading RPlugin and pasting this in the command line in WEKA:
export R_HOME=/Library/Frameworks/R.framework/Resources
java -Xss10M -Xmx4096M -cp .:weka.jar weka.gui.GUIChoose

This however did not work either and R does not run.

If anyone has a very specific step-by-step guide to getting XGBoost on macOS please let me know!

Kind regards,
PYB
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
Reply | Threaded
Open this post in threaded view
|

Re: XGBoost Installation

xgboost
I am also using SVM, though it never completes in running time. I have increased the cache size to 1000 however that has little effect.
Are there parameters I can set such that SVM will run in under an hour.

Kind regards,
Prakash

On Sun, Jun 6, 2021 at 10:27 AM Prakash Bhagat <[hidden email]> wrote:
Thanks, 
I did so however in my problem the cost of a False Positive is 5 times more than a False Negative thus the confusion matrix used is [0.0 1.0; 5.0 0.0]. When implementing the setting you suggested I get an accuracy of 57% still relatively low. 
The highest I was able to get was 67% when using nrounds=1000.
Could it just be that XGBoost does not work as well as knn and rf for this case or am I missing something?

Kind regards,
Prakash

On Sun, Jun 6, 2021 at 2:13 AM Eibe Frank <[hidden email]> wrote:
Looking at the configuration string I posted, you will see

-learner classif.xgboost -params nrounds=100,max_depth=3,subsample=0.5,colsample_bynode=0.5

The

-params

flag introduces the parameters that will be used for the MLR learner that is specified. You need to paste those into the corresponding text field in the GenericObjectEditor when you configure MLRClassifier.

Yes, you should use the same cost matrix.

Cheers,
Eibe

On Sun, Jun 6, 2021 at 1:09 PM Prakash Bhagat <[hidden email]> wrote:
Thanks so much for this!
For your first point, how do I set a minimum number of boosting iterations?
I have looked within the MLR classifier setting however see no option for min iterations.
If I use a cost matrix in the classifier then under more options for test I should create the same confusion matrix, correct?

Kind regards,
Prakash

On Sat, Jun 5, 2021 at 12:56 PM Eibe Frank <[hidden email]> wrote:
The default number of iterations used by XGBoost when applied through the RPlugin is 1. You definitely need to increase the number of boosting iterations. I would also switch the CostSensitiveClassifier to use the minimum-expected cost approach, not the default approach based on reweighting the training data.

Of course, you should also specify the same cost matrix for evaluation under "More options..." in the Classify tab.

The following configuration worked well in a quick try on the sonar data from the UCI repository:

weka.classifiers.meta.CostSensitiveClassifier -cost-matrix "[0.0 5.0; 1.0 0.0]" -M  -W weka.classifiers.mlr.MLRClassifier -- -learner classif.xgboost -params nrounds=100,max_depth=3,subsample=0.5,colsample_bynode=0.5

You can right-click on the text field containing the classifier configuration in the Classify panel and paste the above configuration into the Explorer (assuming you have a dataset with only two classes, it should work).

The reason for using the minimum-expected cost mode of the CostSensitiveClassifier is that it does not change the training data. The default mode of the CostSensitiveClassifier uses instance weights in the training data to reflect costs. I don't know how well that works in conjunction with MLRClassifier.

Cheers,
Eibe

On Sat, Jun 5, 2021 at 11:33 PM Prakash Bhagat <[hidden email]> wrote:
Thanks very much,

I have managed to get windows access and followed the tutorial on youtube for downloading the rplugin. I am using xgboost as a classification method and comparing it to random forests. Random forest gives an accuracy of 75% whereas XGBoost gives an accuracy of only 52%. I was wondering if you could help me as i may have made some errors when implementing xgboost. 
I have attached the data used. I filled in missing values for revol_util and converted nominal features to binary when using xgboost. 
I then used the costsensitiveclassifier with a 5 to 1 cost for false positives and used 5 fold cross-validation. Following this, I used mlrclassifier and used classif.xgboost under Rlearner.
I will do hyper parameter tuning after but was wandering if i had made a mistake with xgboost as the accuracy is so low.
Any help would be much appreciated!

Kind regards,
Prakash

On Sat, Jun 5, 2021 at 4:16 AM Eibe Frank <[hidden email]> wrote:
You cannot set environment variables, etc., in WEKA's built-in CLI, which is really quite primitive and only pretends to be a proper OS terminal! You need to run the command in the macOS terminal. However, as I said, you should not set R_HOME explicitly unless you have installed R in a non-standard location. WEKA's RPlugin will find R on the Mac if it is installed in the standard place.

Cheers,
Eibe

On Sat, Jun 5, 2021 at 1:43 PM Prakash Bhagat <[hidden email]> wrote:
Yes, I have followed this guide: https://riptutorial.com/weka/topic/7916/how-to-use-r-in-weka
I pasted this in the command line in WEKA: export R_HOME=/Library/Frameworks/R.framework/Resources
java -Xss10M -Xmx4096M -cp .:weka.jar weka.gui.GUIChooser

And this is the error from weka:

Kind regards,
Prakash



On 04 Jun,2021, at 13:52, Eibe Frank <[hidden email]> wrote:

Are you still running WEKA with R_HOME set to some value? It is normally best to let WEKA set the value of R_HOME itself.

If there are any error messages shown in the terminal from which you run WEKA, it would be useful to share those.

Cheers,
Eibe

On Fri, Jun 4, 2021 at 11:43 PM Prakash Bhagat <[hidden email]> wrote:
https://github.com/SigDelta/weka-xgboost/releases - This is the link I used to download xgboost.
Using this downloaded I installed xgboost as an unofficial package in tools. It then comes under trees however does not run.

With the RPlugin the MLR classifier is unavailable to use. I have downloaded a new version of R and within R I also downloaded the MLR package. This still however does not run.
I have installed rJava within R as well.
<Screenshot 2021-06-04 at 11.51.31.png>
On 04 Jun,2021, at 11:07, Eibe Frank <[hidden email]> wrote:

Which unofficial version do you mean? Both, RPlugin and wekaPython, are official packages, and both enable you to use XGBoost. With the RPlugin, you need to use XGBoost through the MLRClassifier and select XGBoost as the base learner (the first time you select this base learner, it will try to install it in R, which may take a while). Similarly, with wekaPython, you also need to use the corresponding ScikitLearnClassifier in WEKA with XGBoost as the base learner (and you need to have XGBoost installed in your relevant Python environment, which you may need to do manually).

The easiest way to use XGBoost in WEKA is probably through the RPlugin because the only manual work you (normally) need to do is to install R.

There might be an unofficial WEKA package for XGBoost out there, but it may not be maintained.

Cheers,
Eibe


On Fri, Jun 4, 2021 at 4:49 PM <[hidden email]> wrote:
Dear All,

I have a mac with the latest version of R and python installed. I am using WEKA for an assignment and need to use XGBoost.
I have tried downloading the unofficial version as a package however that does not work.
I then tried the R Plugin version downloading RPlugin and pasting this in the command line in WEKA:
export R_HOME=/Library/Frameworks/R.framework/Resources
java -Xss10M -Xmx4096M -cp .:weka.jar weka.gui.GUIChoose

This however did not work either and R does not run.

If anyone has a very specific step-by-step guide to getting XGBoost on macOS please let me know!

Kind regards,
PYB
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
Reply | Threaded
Open this post in threaded view
|

Re: XGBoost Installation

Eibe Frank
In reply to this post by xgboost
CONTENTS DELETED
The author has deleted this message.
Reply | Threaded
Open this post in threaded view
|

Re: XGBoost Installation

Eibe Frank
In reply to this post by xgboost
CONTENTS DELETED
The author has deleted this message.
Reply | Threaded
Open this post in threaded view
|

Re: XGBoost Installation

xgboost
In reply to this post by Eibe Frank
I checked the AUC score and it was also quite low around 0.55.
The parameters tuned were as follows:
booster = "gbtree",
objective = "binary:logistic",
max_depth = sample(3:10, 1),
eta = runif(1, .01, .3),
subsample = runif(1, .7, 1),
colsample_bytree = runif(1, .6, 1),
min_child_weight = sample(0:10, 1)

I was running weka using bootcamp in Mac however that has crashed and I need to download R for weka using Mac again.
Following your advice I have left R_HOME blank and specified the directory where R for weka was downloaded in step 6 of this : https://riptutorial.com/weka/topic/7916/how-to-use-r-in-weka
I still do not see the mlr classifier however. Please could you help me solve this.

Kind regards,
Prakash

On 07 Jun,2021, at 01:19, Eibe Frank <[hidden email]> wrote:

When you are minimising unequal misclassification cost, plain classification accuracy is not the correct metric to look at!

Also, make sure you turn on the minimum-expected cost option in CostSensitiveClassifier, as mentioned in my earlier message.

You also need to experiment with the other XGBoost parameters, particularly the tree depth. If your dataset exhibits interaction effects between many attributes, you will need to grow deeper trees (max depth 3, as in my example, may not be sufficient).

Cheers,
Eibe

On Mon, Jun 7, 2021 at 12:27 AM Prakash Bhagat <[hidden email]> wrote:
Thanks, 
I did so however in my problem the cost of a False Positive is 5 times more than a False Negative thus the confusion matrix used is [0.0 1.0; 5.0 0.0]. When implementing the setting you suggested I get an accuracy of 57% still relatively low. 
The highest I was able to get was 67% when using nrounds=1000.
Could it just be that XGBoost does not work as well as knn and rf for this case or am I missing something?

Kind regards,
Prakash

On Sun, Jun 6, 2021 at 2:13 AM Eibe Frank <[hidden email]> wrote:
Looking at the configuration string I posted, you will see

-learner classif.xgboost -params nrounds=100,max_depth=3,subsample=0.5,colsample_bynode=0.5

The

-params

flag introduces the parameters that will be used for the MLR learner that is specified. You need to paste those into the corresponding text field in the GenericObjectEditor when you configure MLRClassifier.

Yes, you should use the same cost matrix.

Cheers,
Eibe

On Sun, Jun 6, 2021 at 1:09 PM Prakash Bhagat <[hidden email]> wrote:
Thanks so much for this!
For your first point, how do I set a minimum number of boosting iterations?
I have looked within the MLR classifier setting however see no option for min iterations.
If I use a cost matrix in the classifier then under more options for test I should create the same confusion matrix, correct?

Kind regards,
Prakash

On Sat, Jun 5, 2021 at 12:56 PM Eibe Frank <[hidden email]> wrote:
The default number of iterations used by XGBoost when applied through the RPlugin is 1. You definitely need to increase the number of boosting iterations. I would also switch the CostSensitiveClassifier to use the minimum-expected cost approach, not the default approach based on reweighting the training data.

Of course, you should also specify the same cost matrix for evaluation under "More options..." in the Classify tab.

The following configuration worked well in a quick try on the sonar data from the UCI repository:

weka.classifiers.meta.CostSensitiveClassifier -cost-matrix "[0.0 5.0; 1.0 0.0]" -M  -W weka.classifiers.mlr.MLRClassifier -- -learner classif.xgboost -params nrounds=100,max_depth=3,subsample=0.5,colsample_bynode=0.5

You can right-click on the text field containing the classifier configuration in the Classify panel and paste the above configuration into the Explorer (assuming you have a dataset with only two classes, it should work).

The reason for using the minimum-expected cost mode of the CostSensitiveClassifier is that it does not change the training data. The default mode of the CostSensitiveClassifier uses instance weights in the training data to reflect costs. I don't know how well that works in conjunction with MLRClassifier.

Cheers,
Eibe

On Sat, Jun 5, 2021 at 11:33 PM Prakash Bhagat <[hidden email]> wrote:
Thanks very much,

I have managed to get windows access and followed the tutorial on youtube for downloading the rplugin. I am using xgboost as a classification method and comparing it to random forests. Random forest gives an accuracy of 75% whereas XGBoost gives an accuracy of only 52%. I was wondering if you could help me as i may have made some errors when implementing xgboost. 
I have attached the data used. I filled in missing values for revol_util and converted nominal features to binary when using xgboost. 
I then used the costsensitiveclassifier with a 5 to 1 cost for false positives and used 5 fold cross-validation. Following this, I used mlrclassifier and used classif.xgboost under Rlearner.
I will do hyper parameter tuning after but was wandering if i had made a mistake with xgboost as the accuracy is so low.
Any help would be much appreciated!

Kind regards,
Prakash

On Sat, Jun 5, 2021 at 4:16 AM Eibe Frank <[hidden email]> wrote:
You cannot set environment variables, etc., in WEKA's built-in CLI, which is really quite primitive and only pretends to be a proper OS terminal! You need to run the command in the macOS terminal. However, as I said, you should not set R_HOME explicitly unless you have installed R in a non-standard location. WEKA's RPlugin will find R on the Mac if it is installed in the standard place.

Cheers,
Eibe

On Sat, Jun 5, 2021 at 1:43 PM Prakash Bhagat <[hidden email]> wrote:
Yes, I have followed this guide: https://riptutorial.com/weka/topic/7916/how-to-use-r-in-weka
I pasted this in the command line in WEKA: export R_HOME=/Library/Frameworks/R.framework/Resources
java -Xss10M -Xmx4096M -cp .:weka.jar weka.gui.GUIChooser

And this is the error from weka:
<Screenshot 2021-06-04 at 14.02.40.png>

Kind regards,
Prakash



On 04 Jun,2021, at 13:52, Eibe Frank <[hidden email]> wrote:

Are you still running WEKA with R_HOME set to some value? It is normally best to let WEKA set the value of R_HOME itself.

If there are any error messages shown in the terminal from which you run WEKA, it would be useful to share those.

Cheers,
Eibe

On Fri, Jun 4, 2021 at 11:43 PM Prakash Bhagat <[hidden email]> wrote:
https://github.com/SigDelta/weka-xgboost/releases - This is the link I used to download xgboost.
Using this downloaded I installed xgboost as an unofficial package in tools. It then comes under trees however does not run.

With the RPlugin the MLR classifier is unavailable to use. I have downloaded a new version of R and within R I also downloaded the MLR package. This still however does not run.
I have installed rJava within R as well.
<Screenshot 2021-06-04 at 11.51.31.png>
On 04 Jun,2021, at 11:07, Eibe Frank <[hidden email]> wrote:

Which unofficial version do you mean? Both, RPlugin and wekaPython, are official packages, and both enable you to use XGBoost. With the RPlugin, you need to use XGBoost through the MLRClassifier and select XGBoost as the base learner (the first time you select this base learner, it will try to install it in R, which may take a while). Similarly, with wekaPython, you also need to use the corresponding ScikitLearnClassifier in WEKA with XGBoost as the base learner (and you need to have XGBoost installed in your relevant Python environment, which you may need to do manually).

The easiest way to use XGBoost in WEKA is probably through the RPlugin because the only manual work you (normally) need to do is to install R.

There might be an unofficial WEKA package for XGBoost out there, but it may not be maintained.

Cheers,
Eibe


On Fri, Jun 4, 2021 at 4:49 PM <[hidden email]> wrote:
Dear All,

I have a mac with the latest version of R and python installed. I am using WEKA for an assignment and need to use XGBoost.
I have tried downloading the unofficial version as a package however that does not work.
I then tried the R Plugin version downloading RPlugin and pasting this in the command line in WEKA:
export R_HOME=/Library/Frameworks/R.framework/Resources
java -Xss10M -Xmx4096M -cp .:weka.jar weka.gui.GUIChoose

This however did not work either and R does not run.

If anyone has a very specific step-by-step guide to getting XGBoost on macOS please let me know!

Kind regards,
PYB
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html


_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
Reply | Threaded
Open this post in threaded view
|

Re: XGBoost Installation

Eibe Frank
CONTENTS DELETED
The author has deleted this message.
Reply | Threaded
Open this post in threaded view
|

Re: XGBoost Installation

xgboost
Thanks very much it works now.
I have been changing the parameters in xgboost and found in python best performance based on log loss is with only 50 estimators however when implementing the model 1000 estimators works best.
Additionally, doing the same thing for maximum depth Python found 3 worked best however when using this the results were significantly worse. Using a maximum depth of 10 worked much better.

I’m quite confused by these results as GridsearchCV finds completely different values than the one that actually perform well in the model.
Some graphs of these are attached.

Please could you help me in finding the error.
Thanks!

Kind regards,
Prakash

On 07 Jun,2021, at 10:38, Eibe Frank <[hidden email]> wrote:

That tutorial is for RPlugin in WEKA 3.8.0. The process has been changed, and installation of the RPlugin should now be fully automatic. All you need to do is install R before you install the RPlugin. The RPlugin will find R if it is installed in the standard location, configure all environment variables for you, and also install rJava automatically in R. It is best not to interfere with this process by setting some environment variables yourself.

Cheers,
Eibe

On Mon, Jun 7, 2021 at 8:28 PM Prakash Bhagat <[hidden email]> wrote:
I checked the AUC score and it was also quite low around 0.55.
The parameters tuned were as follows:
booster = "gbtree",
objective = "binary:logistic",
max_depth = sample(3:10, 1),
eta = runif(1, .01, .3),
subsample = runif(1, .7, 1),
colsample_bytree = runif(1, .6, 1),
min_child_weight = sample(0:10, 1)

I was running weka using bootcamp in Mac however that has crashed and I need to download R for weka using Mac again.
Following your advice I have left R_HOME blank and specified the directory where R for weka was downloaded in step 6 of this : https://riptutorial.com/weka/topic/7916/how-to-use-r-in-weka
I still do not see the mlr classifier however. Please could you help me solve this.

Kind regards,
Prakash

On 07 Jun,2021, at 01:19, Eibe Frank <[hidden email]> wrote:

When you are minimising unequal misclassification cost, plain classification accuracy is not the correct metric to look at!

Also, make sure you turn on the minimum-expected cost option in CostSensitiveClassifier, as mentioned in my earlier message.

You also need to experiment with the other XGBoost parameters, particularly the tree depth. If your dataset exhibits interaction effects between many attributes, you will need to grow deeper trees (max depth 3, as in my example, may not be sufficient).

Cheers,
Eibe

On Mon, Jun 7, 2021 at 12:27 AM Prakash Bhagat <[hidden email]> wrote:
Thanks, 
I did so however in my problem the cost of a False Positive is 5 times more than a False Negative thus the confusion matrix used is [0.0 1.0; 5.0 0.0]. When implementing the setting you suggested I get an accuracy of 57% still relatively low. 
The highest I was able to get was 67% when using nrounds=1000.
Could it just be that XGBoost does not work as well as knn and rf for this case or am I missing something?

Kind regards,
Prakash

On Sun, Jun 6, 2021 at 2:13 AM Eibe Frank <[hidden email]> wrote:
Looking at the configuration string I posted, you will see

-learner classif.xgboost -params nrounds=100,max_depth=3,subsample=0.5,colsample_bynode=0.5

The

-params

flag introduces the parameters that will be used for the MLR learner that is specified. You need to paste those into the corresponding text field in the GenericObjectEditor when you configure MLRClassifier.

Yes, you should use the same cost matrix.

Cheers,
Eibe

On Sun, Jun 6, 2021 at 1:09 PM Prakash Bhagat <[hidden email]> wrote:
Thanks so much for this!
For your first point, how do I set a minimum number of boosting iterations?
I have looked within the MLR classifier setting however see no option for min iterations.
If I use a cost matrix in the classifier then under more options for test I should create the same confusion matrix, correct?

Kind regards,
Prakash

On Sat, Jun 5, 2021 at 12:56 PM Eibe Frank <[hidden email]> wrote:
The default number of iterations used by XGBoost when applied through the RPlugin is 1. You definitely need to increase the number of boosting iterations. I would also switch the CostSensitiveClassifier to use the minimum-expected cost approach, not the default approach based on reweighting the training data.

Of course, you should also specify the same cost matrix for evaluation under "More options..." in the Classify tab.

The following configuration worked well in a quick try on the sonar data from the UCI repository:

weka.classifiers.meta.CostSensitiveClassifier -cost-matrix "[0.0 5.0; 1.0 0.0]" -M  -W weka.classifiers.mlr.MLRClassifier -- -learner classif.xgboost -params nrounds=100,max_depth=3,subsample=0.5,colsample_bynode=0.5

You can right-click on the text field containing the classifier configuration in the Classify panel and paste the above configuration into the Explorer (assuming you have a dataset with only two classes, it should work).

The reason for using the minimum-expected cost mode of the CostSensitiveClassifier is that it does not change the training data. The default mode of the CostSensitiveClassifier uses instance weights in the training data to reflect costs. I don't know how well that works in conjunction with MLRClassifier.

Cheers,
Eibe

On Sat, Jun 5, 2021 at 11:33 PM Prakash Bhagat <[hidden email]> wrote:
Thanks very much,

I have managed to get windows access and followed the tutorial on youtube for downloading the rplugin. I am using xgboost as a classification method and comparing it to random forests. Random forest gives an accuracy of 75% whereas XGBoost gives an accuracy of only 52%. I was wondering if you could help me as i may have made some errors when implementing xgboost. 
I have attached the data used. I filled in missing values for revol_util and converted nominal features to binary when using xgboost. 
I then used the costsensitiveclassifier with a 5 to 1 cost for false positives and used 5 fold cross-validation. Following this, I used mlrclassifier and used classif.xgboost under Rlearner.
I will do hyper parameter tuning after but was wandering if i had made a mistake with xgboost as the accuracy is so low.
Any help would be much appreciated!

Kind regards,
Prakash

On Sat, Jun 5, 2021 at 4:16 AM Eibe Frank <[hidden email]> wrote:
You cannot set environment variables, etc., in WEKA's built-in CLI, which is really quite primitive and only pretends to be a proper OS terminal! You need to run the command in the macOS terminal. However, as I said, you should not set R_HOME explicitly unless you have installed R in a non-standard location. WEKA's RPlugin will find R on the Mac if it is installed in the standard place.

Cheers,
Eibe

On Sat, Jun 5, 2021 at 1:43 PM Prakash Bhagat <[hidden email]> wrote:
Yes, I have followed this guide: https://riptutorial.com/weka/topic/7916/how-to-use-r-in-weka
I pasted this in the command line in WEKA: export R_HOME=/Library/Frameworks/R.framework/Resources
java -Xss10M -Xmx4096M -cp .:weka.jar weka.gui.GUIChooser

And this is the error from weka:
<Screenshot 2021-06-04 at 14.02.40.png>

Kind regards,
Prakash



On 04 Jun,2021, at 13:52, Eibe Frank <[hidden email]> wrote:

Are you still running WEKA with R_HOME set to some value? It is normally best to let WEKA set the value of R_HOME itself.

If there are any error messages shown in the terminal from which you run WEKA, it would be useful to share those.

Cheers,
Eibe

On Fri, Jun 4, 2021 at 11:43 PM Prakash Bhagat <[hidden email]> wrote:
https://github.com/SigDelta/weka-xgboost/releases - This is the link I used to download xgboost.
Using this downloaded I installed xgboost as an unofficial package in tools. It then comes under trees however does not run.

With the RPlugin the MLR classifier is unavailable to use. I have downloaded a new version of R and within R I also downloaded the MLR package. This still however does not run.
I have installed rJava within R as well.
<Screenshot 2021-06-04 at 11.51.31.png>
On 04 Jun,2021, at 11:07, Eibe Frank <[hidden email]> wrote:

Which unofficial version do you mean? Both, RPlugin and wekaPython, are official packages, and both enable you to use XGBoost. With the RPlugin, you need to use XGBoost through the MLRClassifier and select XGBoost as the base learner (the first time you select this base learner, it will try to install it in R, which may take a while). Similarly, with wekaPython, you also need to use the corresponding ScikitLearnClassifier in WEKA with XGBoost as the base learner (and you need to have XGBoost installed in your relevant Python environment, which you may need to do manually).

The easiest way to use XGBoost in WEKA is probably through the RPlugin because the only manual work you (normally) need to do is to install R.

There might be an unofficial WEKA package for XGBoost out there, but it may not be maintained.

Cheers,
Eibe


On Fri, Jun 4, 2021 at 4:49 PM <[hidden email]> wrote:
Dear All,

I have a mac with the latest version of R and python installed. I am using WEKA for an assignment and need to use XGBoost.
I have tried downloading the unofficial version as a package however that does not work.
I then tried the R Plugin version downloading RPlugin and pasting this in the command line in WEKA:
export R_HOME=/Library/Frameworks/R.framework/Resources
java -Xss10M -Xmx4096M -cp .:weka.jar weka.gui.GUIChoose

This however did not work either and R does not run.

If anyone has a very specific step-by-step guide to getting XGBoost on macOS please let me know!

Kind regards,
PYB
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html


_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html