Mahout 0.7 random forest examples

#breiman example

hadoop jar $MAHOUT_HOME/core/target/mahout-core-0.7-SNAPSHOT-job.jar org.apache.mahout.classifier.df.tools.Describe -p testdata/glass.data -f testdata/glass.info -d I 9 N L

hadoop jar $MAHOUT_HOME/examples/target/mahout-examples-0.7-SNAPSHOT-job.jar org.apache.mahout.classifier.df.BreimanExample -d testdata/glass.data -ds testdata/glass.info -i 10 -t 100

#partial implementation example

hadoop jar $MAHOUT_HOME/core/target/mahout-core-0.7-SNAPSHOT-job.jar org.apache.mahout.classifier.df.tools.Describe -p testdata/KDDTrain+.arff -f testdata/KDDTrain+.info -d N 3 C 2 N C 4 N C 8 N 2 C 19 N L

hadoop jar $MAHOUT_HOME/examples/target/mahout-examples-0.7-SNAPSHOT-job.jar org.apache.mahout.classifier.df.mapreduce.BuildForest -Dmapred.max.split.size=1874231 -oob -d testdata/KDDTrain+.arff -ds testdata/KDDTrain+.info -sl 5 -p -t 100

hadoop jar $MAHOUT_HOME/examples/target/mahout-examples-0.7-SNAPSHOT-job.jar org.apache.mahout.classifier.df.mapreduce.TestForest -i testdata/KDDTest+.arff -ds testdata/KDDTrain+.info -m ob -a -mr -o predictions

hadoop jar $MAHOUT_HOME/examples/target/mahout-examples-0.7-SNAPSHOT-job.jar org.apache.mahout.classifier.df.tools.ForestVisualizer -ds testdata/KDDTrain+.info -m ob

This entry was posted in mahout and tagged , . Bookmark the permalink.

4 Responses to Mahout 0.7 random forest examples

  1. Rajkumar says:

    Hi,
    the above commands for partial implementation example are working fine.

    can you pls tell me the commands for finding out missing values in bigdata using random forest on mahout?

    Thanks & Regards,
    Rajkumar.

    • Rajkumar says:

      hi,
      for classification the following command works fine.

      hadoop jar $MAHOUT_HOME/examples/target/mahout-examples-0.7-SNAPSHOT-job.jar org.apache.mahout.classifier.df.mapreduce.TestForest -i testdata/KDDTest+.arff -ds testdata/KDDTrain+.info -m ob -a -mr -o predictions

      can you please tell me the commands for regression using randomForest….

  2. Lee says:

    Hi, thank you for your post.
    and my problem is that I don’t have a clue about “.info” file.
    I can get KDDTrain+.arff and glass.data on other sites but what texts have to be in “,info” file?
    Could you upload the files that KDDTrain+.info and glass.info or send me the file on email??
    I really appreciate it if you do. thanks.

Leave a comment