Progress with Rule learning

2 views
Skip to first unread message

Venkatesh U

unread,
Aug 5, 2009, 1:06:50 AM8/5/09
to inqle...@googlegroups.com
Hi Dave,
 I have integrated rapid miner jar with in my java project and created a simple java code to find rules. I could succeed in this. The mined rules can be written in
xml format ( asr format) specific to rapid miner. I think we can read this xml and convert it in to rdf statements. I hope, we can take this forward from here

--
Thanks and Best Regards,

Venkatesh Umaashankar
Mailto    : venka...@gmail.com

Arise, awake and stop not till the goal is reached - Swami Vivekanandha

David Donohue

unread,
Aug 5, 2009, 5:44:21 AM8/5/09
to inqle...@googlegroups.com
Venki,
Great stuff! Does RapidMiner generate a Java class or classes
containing the rules?

To integrate your code into inqle, you could create a new class but
use ClassificationRegressionCrossValidationExperiment as a starting
point. You just have to implement 3 methods:
public AssociationRulesExperiment createClone() - this is trivial
public boolean handlesDataTable(IDataTable dataTable) - return true if
this object can handle the provided IDataTable, otherwise false
public IExperimentResult runExperiment(IDataTable dataTable) - take
the provided IDataTable, run it against the RM experiment, construct
an IExperimentResult object

You will also have to create your own class implementing
IExperimentResult, which will contain all the rules. Let's say this
is called AssociationRulesResult.
Your runExperiment() method will generate an object of class
AssociationRulesResult. If RapidMiner gives you 1 or more Java
objects containing the rules info then you could pull all such rules
info out of these objects via the RM API. If alternatively RM gives
you only an XML document containing the rules info, then you could
parse the out of the XML using an XML API. In either case, your final
product is your AssociationRulesResult object.

Best,
Dave

Venkatesh U

unread,
Aug 5, 2009, 10:20:38 AM8/5/09
to inqle...@googlegroups.com
Hi Dave,
I updated all the bundles to head. The bundle org.inqle.experiment.rapidminer.rules
which we created for adding rules support to inqle only has some errors. Should I delete this bundle
and start from the scratch?

Venki

Venkatesh U

unread,
Aug 5, 2009, 10:31:28 AM8/5/09
to inqle...@googlegroups.com
Dave,
I went through the class
 ClassificationRegressionCrossValidationExperiment

Its really neat, I think its going to make my task very easy.  I want to load some sample data in to inqle, we can load iris flower dataset and get it as IDataTable, convert it to Exampleset and give it to rapid miner. I can continue working on the rapid miner process defenition part. Please help me to get the iris data set in IDataTable format. I am signing off the day. I think  your new changes are going to help my progress a lot.

Thanks,
Venki

On Wed, Aug 5, 2009 at 3:14 PM, David Donohue <d...@daviddonohue.com> wrote:

David Donohue

unread,
Aug 5, 2009, 10:49:27 PM8/5/09
to inqle...@googlegroups.com
Venki,
I am glad it is making sense! You might be making things more complex
than they need to be.

(1) Project org.inqle.experiment.rapidminer.rules might need only 2 classes:
AssociationRulesExperiment
AssociationRulesResult
I suggest you delete all the rest. That should resolve compile errors.

(2) The File Data Importer Wizard handles importing data from
spreadsheet to RDF.

(3) An Inqle sampler handles the pulling a selection of data and
conversion into an IDataTable. When you create your
IRapidMinerExperiment class and you declare it in plugin.xml, that
tells inqle that this experiment exists. You should see it listed
under "RapidMiner Experiments", and you should be able to select it in
the wizard for creating a customized experimenter agent. So in the
UI, you can configure a sampler to select from your datamodel
containing the iris data set. In the UI, you can configure an
Experimenter Agent to use that sampler and to use your new RM
experiment. Finally save this customized sampler and run it. It will
do all the steps of getting a sample of data (would load the entire
iris example set, as this has < 500 samples), converting to
IDataTable, and calling the methods of your AssociationRulesExperiment
class to take that IDataTable and save the resulting
AssociationRulesResult object.

I hope this simplifies things. Literally, your project
org.inqle.experiment.rapidminer.rules might need only 5 files:
plugin.xml,
MANIFEST.MF,
AssociationRulesExperiment.java
AssociationRulesResult.java
AssociationRulesExperiment.xml (the RapidMiner experiment XML file)

Best,
Dave
Reply all
Reply to author
Forward
0 new messages