two graph side by side

17 views
Skip to first unread message

Abhijit Bhattacharyya

unread,
Jul 21, 2022, 1:08:35 PM7/21/22
to dislin-users
Dear *,
I want to plot two line curves in two different graphs plotted in same page side by side i.e. place along X separated by some space with different X and Y data. I tried to play with axspos(nx, ny) while I see graphs are overlaid on the other.
Any idea to handle it?
Best Regards
Abhi

Helmut Michels

unread,
Jul 21, 2022, 2:19:07 PM7/21/22
to dislin-users
Dear Abhi,

axspos is the correct routine for positioning axis systems. The sequence of routines
for plotting multiple axis systems should be:

      axspos (nx, ny);
      graf (...);
      curve (...);
      endgrf ();

      axspos (nx2, ny2);
      graf (...);
      curve (...);
      endgrf ();

      etc.

There are some examples at https://www.dislin.de/examples.html with having multiple
axis systems on a page.

With best regards,

Helmut

Abhijit Bhattacharyya

unread,
Jul 21, 2022, 2:23:49 PM7/21/22
to dislin-users
Dear Helmut,
Thanks a lot. Yes, I did this sequence before writing to you checking the example on bar graph. The issue is that the concept of (nxi, nyi) is not clear. Also I do not understand how to scale down each graph to fit graphs side by side including legends.
Best Regards
Abhi

Helmut Michels

unread,
Jul 21, 2022, 2:33:09 PM7/21/22
to dislin-users
Dear Abhi,

the size of an axis system can be defined with the routine axslen (nxl, nyl) before the graf routine.
axspos defines the lower left corner of an axis system. If you change the parameters in axspos
for the next axis system, the new axis system will be plotted at the new position.

With best regards,

Helmut

Abhijit Bhattacharyya

unread,
Jul 21, 2022, 2:57:26 PM7/21/22
to dislin-users
Dear Helmut,
You are Great. Yes, I was searching command like this. The issue is resolved with axslen(nx, ny);
Best Regards
Abhi
Reply all
Reply to author
Forward
0 new messages