sorry forgot to attach the code:
infile "F:\data\wvar.csv" DSD MISSOVER;
sig = 0;
y = symput('res');
_n_= _n_ +1;
sig2 = 0.0000624 + 0.1438*y*y + 0.634*sig*sig;
sig = sqrt(sig2);
PROC EXPORT DATA=test1
Can you explain what portion of your code is related to SAS/GRAPH or ODS GRAPHICS? This code is probably better posted in either the SAS Procedures forum or the Data Step and Macro Language forum. Since I do not see ANY graph procedures in your code, I don't understand why your posting is here.
Also, many folks do not have SAS 9.0 to test with. For help with older versions of SAS, you may want to work with SAS Tech Support. You also may want to look at the syntax for CALL SYMPUT (which is something that the folks in the Macro forum could help with). I believe you have coded at least one statement with SYMPUT incorrectly. Also, you are using the DO incorrectly and should be getting error messages in your log. What are those error messages?
I would suggest that you collect this information and repost your question in the correct forum and not in the graphics forum.
You need to explain your algorithm. Basically you should get rid of any attempt to loop over the data. The basic data step will take care of that for you. You should RETAIN the values that you want to carry forward (retain) to the next observation.
Your CSV file says the name of the variable is WVAR, so I have modified the code to use that name instead of RESIDUALS. (not sure why it would be plural anyway).
You do not define Y in your program. I have assumed it is yet another name for the data in the CSV file.
Perhaps you want something like this?
infile "F:\data\wvar.csv" DSD MISSOVER firstobs=2;
input wvar ;
retain sig 0;
sig2 = 0.0000624 + 0.1438*wvar*wvar + 0.634*sig*sig;
sig = sqrt(sig2);
Registration is open! SAS is returning to Vegas for an AI and analytics experience like no other! Whether you're an executive, manager, end user or SAS partner, SAS Innovate is designed for everyone on your team. Register for just $495 by 12/31/2023.
If you are interested in speaking, there is still time to submit a session idea. More details are posted on the website.
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.