Jump to content

Hi there, Is there a way to display the daily line chart wit...


Recommended Posts

Posted

Hi there,

Is there a way to display the daily line chart with custom intervals Like if i have a daily chart, i want to line to still display the daily, but the x axis will only display every 2 days.

In excel, this is done by setting the Major Unit to say 2 days and minor of 1 day.

Thank you

Glen

Posted

The following code does every other day for x-axis labels. Is that what you are looking for

DEFINE FILE ggsales

DateYYMD/YYMD = AYMD(&DATEH8,-SEQ_NO,'I8YYMD');

DateA8YYMD/A8YYMD = DateYYMD;

DateMD/A6 = EDIT(DateA8YYMD,'$$$$99/99');

END

GRAPH FILE ggsales

SUM UNITS

BY DateYYMD NOPRINT

BY DateMD

WHERE READLIMIT IS 30

ON GRAPH PCHOLD FORMAT JSCHART

ON GRAPH SET LOOKGRAPH LINE

ON GRAPH SET AUTOFIT ON

ON GRAPH SET STYLE *

INCLUDE=enwarm.sty, $

TYPE=REPORT, CHART-SERIES-LAYOUT=stacked, $

TYPE=DATA, COLUMN=N1, BUCKET=x-axis, $

TYPE=DATA, COLUMN=N2, BUCKET=x-axis, $

TYPE=DATA, COLUMN=N3, BUCKET=y-axis, $

*GRAPH_SCRIPT

setSkipCount(getO1Label(),1);

setTextRotation(getO1Label(),0);

*GRAPH_JS_FINAL

xaxis: { title: {visible: false} },

yaxis: { title: {visible: false},

majorGrid: { visible:true,

lineStyle: {width: 1, color:'silver'}

}

}

*END

ENDSTYLE

END

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
  • Create New...