NBTree is a hybrid between Naive Bayes and decision trees. The model, roughly speaking, is a tree with feature tests separating branches and Naive Bayes models on its leaves. Recently, I stumbled upon the need to implement a data analysis method employing this model, but I couldn't find a pure R package containing NBTree.
I found out that the Java library Weka contains this hybrid model, and Weka can be plugged into R via rWeka. In spite of seeming victory, I soon realized that NBTree didn't come right out of the box and I needed to undergo some hassle to get it working. Here I have documented the steps just in case anyone else is in need of this model and doesn't want to spend the evening reverse-engineering.
Step 1: Installing and loading R packages
Open up a R prompt and install RWeka along with its dependencies. You will have to have a working Java environment installed.
Step 2: Install add-on from Weka package manager
Weka comes with a package system and manager (as there aren't enough package managers in the world already). We will have to use this package manager to install the NBTree add-on as shown below.
Step 3: Test that it was installed properly
You should see similar output as outlined below.
Step 4: Register classifier and bind to variable name
Step 5: Test on Iris data set
Your R environment may be pre-loaded with the Iris data set. If such is the case, you can quickly test if the method is working.
Installing other Weka add-ons
Following these instructions you can perhaps install other add-ons successfully as well. A listing of all add-ons can be queried using the package manager.