Hello
What is wrong with this proc format code??
I get an error
4917 low <- -5000 = '<-5000'
-
22
200
ERROR 22-322: Syntax error, expecting one of the following: (, ',', -, =.
ERROR 200-322: The symbol is not recognized and will be ignored.
proc format;
value ffmt
. = 'Missing'
low <- -5000 = '<-5000'
-5000 <- 0 = '[-5000,0)'
0 <- 1000 = '[0, 1000)'
1000 <- 5000 = '[1000 , 5000)'
5000 <- 10000 = '[5000, 10000)'
10000<-high='>10000';
run;
Using <- in
low <- -5000 = '<-5000
is the problem. Which value starts the range, if you exclude the lowest value?
I updated the format low - -5000 by removing the < and it works, please check.
proc format;
value ffmt
. = 'Missing'
low - -5000 = '<-5000'
-5000 <- 0 = '[-5000,0)'
0 <- 1000 = '[0, 1000)'
1000 <- 5000 = '[1000 , 5000)'
5000 <- 10000 = '[5000, 10000)'
10000<-high='>10000';
run;
April 27 – 30 | Gaylord Texan | Grapevine, Texas
Walk in ready to learn. Walk out ready to deliver. This is the data and AI conference you can't afford to miss.
Register now and save with the early bird rate—just $795!
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.