keep only variables(columns) showing up in another table as row values

Hi helper,

The answer might be straightforward but  I just cannot figure it out.  I have table 1 include all variabels (X1, X2,X3,X4), and table 2 only have one column called "Variables" and 2 rows with value "X1" and "X2". my question is how can I reshape table 1 so it can only include variables X1 and X2, which are defined from column "variables" from table 2. < more like a keep statement is DATA step in SAS>

The application of the logic is after I run "InformationGainCalulator" node, I get a list of variables with IG, and I put a filter there to get the list of variables I want to keep (like table 2 above), then I need to remove other variables in original table (table 1 above) so I can get a smaller table for next step.

Any help will be appreciated!

Joven

 

 

Hi,

You can try the workflow in attachement.

Best regards,

Fabien

 

thanks fabienc for your kind/prompt help, this works perfectly! :-)  

Just wondering why such a simple task will need so many steps. I was trying to create a variable "keep list" saved to flow variable without success, which seems more straightforward to me.