"Filtering the examples"

Shubha
Shubha New Altair Community Member
edited November 5 in Community Q&A
Hi RM,

I need to filter out a few examples in my ExampleSet. Say suppose, I have a single nominal attribute, with the examples as:

Rapid Miner
Operators *
Process * Log
Country = XYZ
State = ABC

I need to filter out the examples which contains = or *. How do i do this? I tried with the ExampleFilter with the option "Attribute Value Filter". But was not able to get it.

Thanks,
Shubha

Answers

  • haddock
    haddock New Altair Community Member
    If you have actually tried this then please post data and process code, without which no comment is feasible.
  • Shubha
    Shubha New Altair Community Member
    Here's the xml code...

    <operator name="Root" class="Process" expanded="yes">
        <operator name="ExampleSource" class="ExampleSource">
            <parameter key="attributes" value="C:\Documents and Settings\shubhak\Desktop\Trial.aml"/>
        </operator>
        <operator name="ChangeAttributeNames2Generic" class="ChangeAttributeNames2Generic">
        </operator>
    </operator>



    And the data is attached as "ToRead.txt".

    [attachment deleted by admin]
  • haddock
    haddock New Altair Community Member
    Not sure how you imagined that would filter your examples, but this does.
    <operator name="Root" class="Process" expanded="yes">
        <operator name="NominalExampleSetGenerator" class="NominalExampleSetGenerator">
        </operator>
        <operator name="Mapping" class="Mapping" breakpoints="after">
            <parameter key="attributes" value="att1"/>
            <list key="value_mappings">
              <parameter key="blob*blob" value="value1"/>
              <parameter key="blob=blob" value="value2"/>
            </list>
        </operator>
        <operator name="ExampleFilter" class="ExampleFilter">
            <parameter key="condition_class" value="attribute_value_filter"/>
            <parameter key="parameter_string" value="att1=.*=.*|.*\*.*"/>
            <parameter key="invert_filter" value="true"/>
        </operator>
    </operator>
  • Shubha
    Shubha New Altair Community Member
    Thank you very much Haddock... That worked...