Hi , Would you please let me know how to convert the codes below to macro if SC value change as 1,2,3,4,5,6 ? Thank you Data work.want; Set work.have; if SC=1 and u_rep =1 and ((co1*(Daily**2))+(co_dem_1*daily)+(int_1))>99.7 then exp_val =1; Else if SC=1 and u_rep =1 and ((co1*(Daily**2))+(co_dem_1*daily)+(int_1))<99.7 then exp_val=(( co_dem_1*((co1*(Daily**2))+(co_dem_1*daily)+(int_1))/100 ; if SC=2 and u_rep =1 and ((co2*(Daily**2))+(co_dem_2*daily)+(int_2))>99.7 then exp_val =1; Else if SC=2 and u_rep =1 and ((co2*(Daily**2))+(co_dem_2*daily)+(int_2))<99.7 then exp_val=(( co_dem_2 *((co2*(Daily**2))+(co_dem_2*daily)+(int_2))/100 ; if SC=3 and u_rep =1 and ((co3*(Daily**2))+(co_dem_3*daily)+(int_3))>99.7 then exp_val =1; Else if SC=2 and u_rep =1 and ((co3*(Daily**2))+(co_dem_3*daily)+(int_3))<99.7 then exp_val=(( co_dem_3 *((co3*(Daily**2))+(co_dem_3*daily)+(int_3))/100 ;
... View more