Skip to Content
-2

I want to draw comparative curve graphs

Oct 27, 2017 at 05:17 PM

69

avatar image
Former Member

I want to draw comparative curve graphs using ABAP given in below format

graph.png (9.0 kB)
10 |10000 characters needed characters left characters exceeded

And what is your question?

0
* Please Login or Register to Answer, Follow or Comment.

2 Answers

Sandra Rossi Oct 28, 2017 at 08:01 PM
1

With STAT_GRAPH_REF, each "curve" must have the same number of points. So, it's impossible to achieve your goal using this function module.

Instead, use STAT_GRAPH, which allows any number of points in each curve.

Show 3 Share
10 |10000 characters needed characters left characters exceeded
Former Member

Hi Sandra,

Is it possible to draw comparison curve graph using STAT_GRAPH as I have to draw actual curve and planned curve graph.

0

I thought that my answer was clearly Yes.

So, to be more clear, if you want something like:

Then use a code like this one:

DATA: OPTS TYPE TABLE OF char80,
      BEGIN OF DATA OCCURS 1,
        X TYPE I,
        Y TYPE I,
      END OF DATA.
APPEND '$2     ' TO opts. " the 1st curve has 2 points
APPEND 'COLOR=5' TO opts. " MAGENTA
APPEND '$3     ' TO opts. " the 2nd curve has 3 points
APPEND 'COLOR=4' TO opts. " GREEN
" the 1st curve has 2 points
data-x = 2. data-y = 4. APPEND data.
data-x = 4. data-y = 5. APPEND data.
" the 2nd curve has 3 points
data-x = 1. data-y = 8. APPEND data.
data-x = 3. data-y = 7. APPEND data.
data-x = 5. data-y = 4. APPEND data.
CALL FUNCTION 'STAT_GRAPH'
  TABLES
    opts = opts
    data = data.
rvmoi.png (14.8 kB)
1
Former Member

Thanks for your help

0
avatar image
Former Member Oct 28, 2017 at 05:01 AM
-1

Facing issue to draw second graph (red color ) after point 3 of X axis graph is going in continue format. I want to stop continue plotting of graph.

I am using STAT_GRAPH_REF function module.

Share
10 |10000 characters needed characters left characters exceeded