BookmarkSubscribeRSS Feed
Jagadishkatam
Amethyst | Level 16

Dear All,

This is a issue i observed when the graph in pdf format created in sas 9.1 version is executed in sas 9.3. The graph when executed in sas 9.1 , generated the output in the outfile location as mentioned. However when the same graph is executed in sas 9.3 with the same outfile location, is saving the graph in the work area but not in the outfile location. could you please let me know the reason for this.

There is no error or warning observed.

i am using the proc gplot , proc greplay procedures. what i observed from the log is that the gsasfile is able to resolve to the given outfile location but the output pdf file saved to the work area.

Any suggestions.

Thanks,

Jag

Thanks,
Jag
2 REPLIES 2
Cynthia_sas
SAS Super FREQ

Hi:

  I am not sure why you are using GSASFILE if you are creating a PDF file. Normally, if you do this:
  

**SAS/GRAPH GPLOT step that makes image in GSEG catalog;
   

ODS PDF file=...;

**your proc greplay code here;

ODS PDF CLOSE;
   

  Then ODS PDF would "grab" your GREPLAY image and insert it into the PDF file. No GSASFILE needed. Usually, you use GSASFILE when you want to create an image without the "wrapper" document.
     

  However, since you did not post any code, it is very hard to comment on the specifics of your question beyond the most general. For example -- yes, between SAS 9.1.3 and SAS 9.2/9.3, there were significant changes that could impact PDF file creation or any image creation because of the SAS/GRAPH and ODS GRAPHICS changes to support style templates and the introduction of the new fonts and font handling routines as described in these papers:

http://support.sas.com/resources/papers/proceedings10/035-2010.pdf

http://support.sas.com/resources/papers/proceedings12/260-2012.pdf
      

  My recommendation is that you work with Tech Support where they can look at ALL your code, including your ODS statements and ALL your data and help you come to the best resolution. I am including below an example of creating an ODS PDF file using PROC SGPANEL, just to illustrate the simplicity of the new ODS GRAPHICS framework to make "paneled" output where no GREPLAY (and no GSASFILE) is needed. The program to make the data is longer than the SGPANEL code to make the paneled output.
     

Cynthia

title;

footnote;

  

data diffrept;

  infile datalines;

  input id year district $ quarter $ sales ovsales ovmean SalesM;

  label salesM='Sales M' quarter='Quarter' year='Year';

return;

datalines;

1 2005 Eastern Q1 1328353 7003157 69338 1

2 2008 Eastern Q1 4602760 24656068 244119 5

3 2007 Eastern Q1 3110877 15739483 155836 3

4 2006 Eastern Q1 1975103 10571027 104664 2

5 2006 Eastern Q2 2567901 10571027 104664 3

6 2005 Eastern Q2 1675072 7003157 69338 2

7 2008 Eastern Q2 5484460 24656068 244119 5

8 2007 Eastern Q2 3539148 15739483 155836 4

9 2005 Eastern Q3 1493637 7003157 69338 1

10 2008 Eastern Q3 5553238 24656068 244119 6

11 2006 Eastern Q3 2308344 10571027 104664 2

12 2007 Eastern Q3 3383560 15739483 155836 3

13 2008 Eastern Q4 9015610 24656068 244119 9

14 2007 Eastern Q4 5705898 15739483 155836 6

15 2006 Eastern Q4 3719679 10571027 104664 4

16 2005 Eastern Q4 2506095 7003157 69338 3

17 2006 Northern Q1 2808461 16048901 180325 3

18 2008 Northern Q1 5892159 35896239 403329 6

19 2005 Northern Q1 2083621 10736953 120640 2

20 2007 Northern Q1 4145410 24450801 274728 4

21 2005 Northern Q2 2904575 10736953 120640 3

22 2008 Northern Q2 10093321 35896239 403329 10

23 2006 Northern Q2 4433031 16048901 180325 4

24 2007 Northern Q2 6889802 24450801 274728 7

25 2008 Northern Q3 8505877 35896239 403329 9

26 2006 Northern Q3 4160575 16048901 180325 4

27 2005 Northern Q3 2556765 10736953 120640 3

28 2007 Northern Q3 5979722 24450801 274728 6

29 2008 Northern Q4 11404881 35896239 403329 11

30 2006 Northern Q4 4646834 16048901 180325 5

31 2007 Northern Q4 7435866 24450801 274728 7

32 2005 Northern Q4 3191992 10736953 120640 3

33 2006 Southern Q1 2176237 9237633 115470 2

34 2008 Southern Q1 4341367 21270560 265882 4

35 2007 Southern Q1 2999372 14014506 175181 3

36 2005 Southern Q1 1301463 5835606 72945 1

37 2008 Southern Q2 6795370 21270560 265882 7

38 2006 Southern Q2 2636832 9237633 115470 3

39 2005 Southern Q2 1675487 5835606 72945 2

40 2007 Southern Q2 4336665 14014506 175181 4

41 2008 Southern Q3 4135367 21270560 265882 4

42 2006 Southern Q3 1837990 9237633 115470 2

43 2005 Southern Q3 1229418 5835606 72945 1

44 2007 Southern Q3 2825947 14014506 175181 3

45 2008 Southern Q4 5998456 21270560 265882 6

46 2006 Southern Q4 2586574 9237633 115470 3

47 2005 Southern Q4 1629238 5835606 72945 2

48 2007 Southern Q4 3852523 14014506 175181 4

49 2006 Western Q1 3382066 16756694 159588 3

50 2005 Western Q1 2071726 10819902 103047 2

51 2008 Western Q1 7142211 36630672 348864 7

52 2007 Western Q1 4676172 24235628 230816 5

53 2008 Western Q2 7806385 36630672 348864 8

54 2006 Western Q2 3225797 16756694 159588 3

55 2005 Western Q2 2131626 10819902 103047 2

56 2007 Western Q2 5253327 24235628 230816 5

57 2005 Western Q3 3621846 10819902 103047 4

58 2006 Western Q3 5957215 16756694 159588 6

59 2008 Western Q3 13885152 36630672 348864 14

60 2007 Western Q3 8813771 24235628 230816 9

61 2007 Western Q4 5492359 24235628 230816 5

62 2005 Western Q4 2994704 10819902 103047 3

63 2006 Western Q4 4191616 16756694 159588 4

64 2008 Western Q4 7796924 36630672 348864 8

;

run;

       

options gstyle nodate nonumber;

ods listing close sge=off;

ods pdf file="c:\temp\smallplot_odsgraf.pdf"; 
  

proc sgpanel data=diffrept;

  panelby district ;

  vline quarter/response=salesM group=year

        markers markerattrs=(symbol=circlefilled);

  rowaxis values=(0 to 15 by 3);

run;

quit;

ods _all_ close;

ods listing;


odsgraf_nogreplay_nogsasfile.png
Jagadishkatam
Amethyst | Level 16

Hi Cynthia,

The issue was resolved when i used the following code just above the proc gplot procedure

goptions gsfname=file;

filename file"~Path/.pdf";

Thanks,

Jag



Thanks,
Jag

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

How to Concatenate Values

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.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 2 replies
  • 969 views
  • 3 likes
  • 2 in conversation