BookmarkSubscribeRSS Feed
Waliyya
Calcite | Level 5

Hello,

I want to make a graph to represent the evolution of the Coca Cola stock. I have tried doing it (see the picture in attachment) with the command below :

proc gplot Skalli.base_union ;

symbol1 interpol=join value=none color=orange ;

plot Coca_cola*Date ;

Title "Evolution de l'action Coca cola" ;

run ;

ods rtf close;

Quit ;

However in my graph I don't have the value on the y-axis (you will see a long black thing instead of the values of the stock)

How do I do to have the values on the y-axis ? I have the comments below in my journal :

WARNING: The gauche vertical axis labeled Yahoo could not be fit as specified. The axis values will overwrite.

WARNING: The number of minor tick marks requested, 0, will result in marks drawn less than a pixel wide. Minor

         tick mark request will be ignored.

Thanking you in advance.


Capture.PNG
5 REPLIES 5
Cynthia_sas
SAS Super FREQ

Hi:

  Generally speaking, sometimes the SG procedures make better assumptions about axis labeling. See this paper and the stock example there that shows the use of ODS GRAPHICS PROC SGPLOT.

Cynthia

from: http://www2.sas.com/proceedings/forum2008/255-2008.pdf

 

proc sgplot data=sashelp.stocks;

yaxis grid;

series x=date y=close / group=stock;

run;

  

proc sgpanel data=sashelp.stocks;

panelby stock / columns=1;

rowaxis grid;

series x=date y=close;

run;

Waliyya
Calcite | Level 5

Thank you very much. However when I use the command SGPLOT I get a blank graph. Can you illustrate the commands you gave me with an example please. I don't understant every line of the command.

Also, I would like to know if you know how to calculate VaR (Value At Risk) on SAS and how to make copulas please.

Thanking you in advance and happy new year.

Reeza
Super User

Try with ODS Graphics On,

If you still don't get a graph generated, contact SAS Tech Support.

ODS GRAPHICS ON;

proc sgplot data=sashelp.stocks;

yaxis grid;

series x=date y=close / group=stock;

run;

Ksharp
Super User

ODS GRAPHICS / width=xxx height=xxx ;

GraphGuy
Meteorite | Level 14

Here is an example using gplot to show how the price and volume of a stock changed over time...

http://www.robslink.com/SAS/democd25/stock.htm

http://www.robslink.com/SAS/democd25/stock_info.htm

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!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

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
  • 5 replies
  • 2053 views
  • 0 likes
  • 5 in conversation