Setting polynomial as having a target role of ID

Reach
Reach New Altair Community Member
edited November 2024 in Community Q&A

Hello,

 

I have got  data where I want to set the role of Firstname as ID. When I try to do it I get the error, that its a polynomial and should be an interger. I then correspondingly do a nominal to numerical transformation. The isssue is however that after I do this, and go to the Set role Operator, there are many first names  under the attribute name list. It would be highly inefficient to select each individual and set as ID and I was wondering whether there was a better process?

 

Thanks.

Tagged:

Answers

  • amund
    amund New Altair Community Member

    If I understand you correctly, you get the actual values of the first names as an attribute when you try to select it in the Set Role operator. Could it be because of the way the data is structured?

     

    Rapidminer would expect the data to be delivered in this format:

     

    First name       Goals scored

    Eric                     2

    Bob                     5

    John                    4

     

  • Thomas_Ott
    Thomas_Ott New Altair Community Member

    @amund might be onto something. You can use Set Role to make a polynominal as an ID. My guess is the metadata is complaining about something in your process and feeding it back to the operator (Set Role) where the mistake is occuring. 

  • Reach
    Reach New Altair Community Member

    Hi,

     

    I just updated to the 7.5 and now get a different error.,

    My data is of the form row no., Firstname, Gender. I first remove duplicate firstnames and then try set to firstname as ID and it doesn't work as per attached. I tried reversing order of removal of duplication and setting as ID but to no avail.

     

    I don't think there are any issues with the data.

  • Edin_Klapic
    Edin_Klapic New Altair Community Member

    Hi Reach,

     

    with the Operator Set Role you can define more than one role.

    The error bubble states that this parameter has been set in this Operator and the role for an Attribute named 'isnumber(search('Firstname'))' shall be changed. Since the Attribute is not given in the ExampleSet the error occurs.

     

    Best,

    Edin