Dear Michael
I think the use of DrawSymbol illustrated in the example below achieves
what you want.
Richard Lewney
Managing Director
Cambridge Econometrics
Covent Garden
Cambridge
CB1 2HS
UK
Email <mailto:[log in to unmask]>
Website http://www.camecon.co.uk
Tel +44 1223 460760
Fax +44 1223 464378
#include <oxstd.h>
#include <oxdraw.h>
main()
{
decl mY, asY, dLowerLeftX, dLowerLeftY, dUpperLeftX, dUpperLeftY,
iBoxIndex;
// Create the data;
mY = rann(2,50);
asY={"First line","Second line"};
// Settings for coloured rectangle to be shaded in chart
dLowerLeftX = 1993;
dLowerLeftY = 0.5;
dUpperLeftX = 1996.5;
dUpperLeftY = -0.4;
iBoxIndex = 6;
// Draw the chart with the mY data
DrawTMatrix(0,mY,asY,1990,1,4);
// Draw the shaded rectangle
DrawSymbol(0,dLowerLeftX, dLowerLeftY, dUpperLeftX, dUpperLeftY,
PL_FILLBOX, iBoxIndex);
ShowDrawWindow();
}
Michael Massmann <[log in to unmask]> on 16/03/2003 13:57:05
Please respond to [log in to unmask]
To: [log in to unmask]
cc:
Subject: colouring of graphs
Dear all,
is there a way of colouring, or shading, specific areas in a graph, for
instance by specifying appropriate world coordinates as boundaries?
Many thanks for your help,
Michael
___________________________________________________
Michael Massmann
Institute of Econometrics and Operations Research
University of Bonn
Adenauerallee 24-42
53113 Bonn
Germany
phone: +49 (0)228 733925
fax: +49 (0)228 739189
email: [log in to unmask]
|