Hello, I have a dataset I want to create a format from, but then I want to add an 'other' clause to assign a value for things that are not included in the dataset. Sorry if this is a simple question but I don't know how to go about doing this. Thank you.
This page should help you: https://documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/proc/n1e19y6lrektafn1kj6nbvhus59w.htm
The `if last then do` portion takes care of the `other` clause you mentioned.
This page should help you: https://documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/proc/n1e19y6lrektafn1kj6nbvhus59w.htm
The `if last then do` portion takes care of the `other` clause you mentioned.
One of the best ways I found to "learn" the options for CNTLIN data sets is to create small example formats or informats and create an output data set with the CNTLOUT option. Then look at the values set for the variables.
HLO is variable that you set values for to indicate the key words "High", "Low" and "Other" for the format/informat value range (hence HLO)
Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.