SAS Data Integration Studio, DataFlux Data Management Studio, SAS/ACCESS, SAS Data Loader for Hadoop and others

Incorrectly labelled values

Occasional Contributor
Posts: 8

Incorrectly labelled values

[ Edited ]

I'm trying to categorize variables in one tables based on the conditions coming from another table. Currently im using macro which assigns categories (by creating a new table and putting categories under the variables) to those values however it seems that it is assigining them even if the value doesnt not meet the conditions. For example 2nd value of first variable is 78 which should be category 2 but it still assigns it to category 1.

With this post I'm providing the two datasets(tables)- one is for categorization conditions and the other one is containing all the variables with values.

Super User
Posts: 13,295

Re: Incorrectly labelled values

Instructions here: will show how to turn an existing SAS data set into data step code that can be pasted into a forum code box using the {i} icon or attached as text to show exactly what you have and that we can test code against.



Provide the minimum amount of data to demonstrate your issue and show us what the result should be for any supplied example data.


I'm not following your code as to what is to be accomplished but it almost sound like some of the "condition" information might be useable to build formats??

Ask a Question
Discussion stats
  • 1 reply
  • 2 in conversation