Hi SAS users,
Can the byte function be used in sas studio?
data a ; plusmin = byte(177); run; proc print data = a ; run;
If I used the above code and can not get the plus minus sign in the dataset nor the print table.
Thank you.
What font are you using (active ODS Style)? The ASCII values above 127 numeric value are quite font dependent. In my set up I see a plus/minus sign.
Please do not double post 🙂
What happens in your log when you run this?
data _null_;
plusmin = byte(177);
put plusmin;
run;
What font are you using (active ODS Style)? The ASCII values above 127 numeric value are quite font dependent. In my set up I see a plus/minus sign.
Are you using Unicode? If so you need the two byte sequence 'C2B1'x and not just 'B1'x.
If you are not using Unicode then any code that needs more than 7 bits (greater than 127 base 10) will display differently in different fonts.
It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.
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.