BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
tparvaiz
Obsidian | Level 7

Hi,

I am using Proc GChart to display some graphical bars.. in my table I have dates for 14 days but the graph is displaying just random dates and the associated data.

as an example, I have dates from June 26 2012 to July 9 2012 but graph is showing only 26 June, 29 June 2 July 5 July and 8 July

here is my data

CATEGORYDAY_DATEVOLUME
COM_126Jun2012165,568
COM_127Jun2012134,287
COM_128Jun2012198,094
COM_129Jun2012197,668
COM_130Jun2012142,697
COM_101Jul2012157,581
COM_102Jul2012196,513
COM_103Jul2012174,259
COM_104Jul2012102,094
COM_105Jul2012105,536
COM_106Jul201293,170
COM_107Jul2012129,333
COM_108Jul2012138,129
COM_109Jul2012148,199

Here is the code that I am using

axis1 minor=none label=('Volumes');

axis2 minor=none label=(f='Arial/Bold' justify=centre 'Days')

value = (font="Arial" height = 8pt);

title1 'Title1';

PROC GCHART DATA=WORK.TABLE;

  VBAR3D

  DAY_DATE

/

SUMVAR=VOLUME

  SHAPE=Cylinder

FRAME TYPE=SUM

SUM

  LEGEND=LEGEND1

  COUTLINE=BLACK

  RAXIS=AXIS1

  MAXIS=AXIS2

PATTERNID=MIDPOINT

  LREF=1

  CREF=BLACK

  AUTOREF

  space=0

;

  BY CATEGORY;

RUN; QUIT;

Please advice

Thanks

1 ACCEPTED SOLUTION

Accepted Solutions
QLi
Fluorite | Level 6 QLi
Fluorite | Level 6

to put  "Discrete" Option in the statement of VBAR3D,  try it

PROC GCHART DATA=have;
  VBAR3D
  DAY_DATE / discrete SUMVAR=VOLUME  SHAPE=Cylinder

FRAME TYPE=SUM SUM

  LEGEND=LEGEND1

  COUTLINE=BLACK

  RAXIS=AXIS1

  MAXIS=AXIS2

PATTERNID=MIDPOINT

  LREF=1

  CREF=BLACK

  AUTOREF

  space=0

;

RUN; QUIT;

View solution in original post

1 REPLY 1
QLi
Fluorite | Level 6 QLi
Fluorite | Level 6

to put  "Discrete" Option in the statement of VBAR3D,  try it

PROC GCHART DATA=have;
  VBAR3D
  DAY_DATE / discrete SUMVAR=VOLUME  SHAPE=Cylinder

FRAME TYPE=SUM SUM

  LEGEND=LEGEND1

  COUTLINE=BLACK

  RAXIS=AXIS1

  MAXIS=AXIS2

PATTERNID=MIDPOINT

  LREF=1

  CREF=BLACK

  AUTOREF

  space=0

;

RUN; QUIT;

SAS Innovate 2025: Register Now

Registration is now open for SAS Innovate 2025 , our biggest and most exciting global event of the year! Join us in Orlando, FL, May 6-9.
Sign up by Dec. 31 to get the 2024 rate of just $495.
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.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 1 reply
  • 540 views
  • 1 like
  • 2 in conversation