"left" moves the number to left. without using "left" function, "c_1" will be "c_ 1". "compress" also takes out extra spaces. Below is the log file without using left function: 1260 Data _null_; 1261 set Temp_Cats; 1262 call symput ("C_" || (_N_), compress(IV_Bin)); 1263 call symput ("n_" || (_N_), left(count)); 1264 call symput ("M", _N_); 1265 Run; NOTE: Numeric values have been converted to character values at the places given by: (Line):(Column). 1262:31 1262:46 1263:31 1263:42 1264:27 ERROR: Symbolic variable name C_ 1 must contain only letters, digits, and underscores. NOTE: Invalid argument to function SYMPUT at line 1262 column 14. ERROR: Symbolic variable name N_ 1 must contain only letters, digits, and underscores. NOTE: Invalid argument to function SYMPUT at line 1263 column 14. IV_Bin=1 count=410 _ERROR_=1 _N_=1 ERROR: Symbolic variable name C_ 2 must contain only letters, digits, and underscores. NOTE: Invalid argument to function SYMPUT at line 1262 column 14. ERROR: Symbolic variable name N_ 2 must contain only letters, digits, and underscores. NOTE: Invalid argument to function SYMPUT at line 1263 column 14. IV_Bin=2 count=35 _ERROR_=1 _N_=2 NOTE: The SAS System stopped processing this step because of errors. NOTE: There were 2 observations read from the data set WORK.TEMP_CATS. NOTE: DATA statement used (Total process time): real time 0.00 seconds cpu time 0.00 seconds
... View more