🦉 🎤   RapidMiner Wisdom 2020 - CALL FOR SPEAKERS   🦉 🎤

We are inviting all community members to submit proposals to speak at Wisdom 2020 in Boston.


Whether it's a cool RapidMiner trick or a use case implementation, we want to see what you have.
Form link is below and deadline for submissions is November 15. See you in Boston!

CLICK HERE TO GO TO ENTRY FORM

Trimming attributes inside LoopValue?

sgtrocksgtrock Member Posts: 17  Maven
edited November 2018 in Help
Hello, all;

I thought this was going to be a straightforward exercise, but it's not working out too well. :-)  I've got a substantial dataset that I need to carve up based upon the values in three attributes.  Once I have the separate collections, I need to add additional data rows in each collection.  This data is based upon a template that needs to be inserted after every row in each collection.

So, what I did was the following:
LoopValue 1
    Filter on attribute 1
    LoopValue 2
        Filter on attribute 2
        LoopValue 3
            Filter on attribute 3
When I do this, I get the expected result;  collections broken down by category, subcategory, and sub-subcategory.  At this point, I need to get rid of the extraneous attributes before adding in the the templates. 

I tried adding a Trim statement inside LoopValue 3.  I trimmed by subset and chose the attributes that I wanted to get rid of.  Reviewing the example set at the input and output of the Trim statement shows that it is not taking effect.  Is this happening because I'm trying to execute inside a loop?

Answers

  • MariusHelfMariusHelf RapidMiner Certified Expert, Member Posts: 1,869   Unicorn
    Hi,

    the Trim operator should work inside a loop, however you won't get rid of any attributes with it. If you want to remove attributes, you have to use Select Attributes.

    Best,
    Marius
  • sgtrocksgtrock Member Posts: 17  Maven
    Sorry, I should have realized that my description needed a little more context.  I defined the Trim operator this way:

    1)  Selected Subset
    2) Opened the Select Attributes... dialog and chose the three attributes that I needed to remove.


    That should have given me every attribute except those three, correct?  Yet the output of the Trim operator remains the same as the input.
  • MariusHelfMariusHelf RapidMiner Certified Expert, Member Posts: 1,869   Unicorn
    No, you have to use the operator "Select Attributes". The Trim operator removes leading and trailing whitespace from nominal attributes, and the selected attributes in its parameters define on which parameters the trimming is applied.
  • sgtrocksgtrock Member Posts: 17  Maven
    :o  D'oh!  I knew that.  :D
Sign In or Register to comment.