BookmarkSubscribeRSS Feed
Ankit_ETL
Calcite | Level 5

Hello everyone,

 

I have created a graph through sgplot which is going to a dashboard (linked via my stored procedure).

The problem is dashboard is designed using XML/html coding. they have specified width of graph as percentage of screen size.

 

I need to do something that my graph automatically changes width as per space allotted. (height is pretty much constant as it is defined in pixels). you have, probably, already guessed what issues arises when I give dimensions for desktop monitor and someone access the dashboard via laptop. (edges goes off and scrolling is needed to see the whole graph).

 

I tried Imagefmt=svg in ods graphics. (didn't work).

 

any advice on how to define graph size to fit the space allotted in dashboard is highly appreciated. 

 

regards

Ankit

 

2 REPLIES 2
ballardw
Super User

You might try setting the image height and width dimensions in the ODS Graphics statement using the PCT or % unit.

 

ods graphics /height=60pct width=80pct;

 

or similar.

 

I won't claim to have used that as most of my output goes to RTF.

Ankit_ETL
Calcite | Level 5
thanks for the reply. appreciate it.
that was the first thing I tried but that doesn't work.
I think (not sure) height =xxpct is xx% of the default height and not % of allotted space in dashboard

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

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
  • 721 views
  • 0 likes
  • 2 in conversation