[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]
RE: st: Labelling lines on graphs
> and, as further extension (the _Nth value is not missing):
> local n = _N + 1
> set obs n
> gen last1 = ser1[_N-1] if _n==_N
> gen last2 = ser2[_N-1] if _n==_N
> gen lab1 = 1 if (_n==_N)
> gen lab2 = 2 if (_n==_N)
> replace year = year[_N-1] + 1 if _n==_N
> gr ser1 last1 ser2 last2 year, s(i[lab1]i[lab2]) c(l.l.) pen(2233)
> Change the "+1" in the replace command to move the
> description in the space
> of the x-axis. Of course, "lab1" etc may be string
> variables to label each
> line with a label sensu strictu.
As yet further decoration note that
... in l
(think -l- for last) is always OK for
... if _n == _N
and faster to execute.
N.B. the correct Latin is sensu stricto...
* For searches and help try: