The Altair Community is migrating to a new platform to provide a better experience for you. In preparation for the migration, the Altair Community is on read-only mode from October 28 - November 6, 2024. Technical support via cases will continue to work as is. For any urgent requests from Students/Faculty members, please submit the form linked here
Logic question
I have a list of grades, and I want to create an attribute that tells me which examples contain a D, F, or W grade (i.e., Y, N). Is there a logic statement that would allow me to do this in the Generate Attribute operator, or is there another operator that would help me to do this?
1
Best Answer
-
varunm1 Member Posts: 1,207 UnicornHello @pb42
You can use generate attributes operator and write a simple if statement. I added a sample .rmp file in this with generate attribute, I used the Titanic dataset where I generated a new attribute named "Class" that will have value "Y" if a passenger belongs to either First or second class and "N" for other classes (Passenger Class attribute).
if(([Passenger Class] == ("First") || [Passenger Class] == ("Second")), "Y", "N")
You can do it similarly for your case. To open the .rmp file in your studio, you can download from here and in studio go to FILE --> Import Process and navigate to the .rmp file downloaded.
Please let us know if this helps you. If you need more, please inform us.Regards,
Varun
https://www.varunmandalapu.com/Be Safe. Follow precautions and Maintain Social Distancing
7
Answers
Varun
https://www.varunmandalapu.com/
Be Safe. Follow precautions and Maintain Social Distancing