Dear Statalist,
I am doing some tsline graphs and I get an error with the "if tin" option.
I have data staring in March 2003 and runs for five years. When I do a graph with twoway tsline, the X axis starts with Jan 2003 and ends in Jan 2008 even if there are no observations. I tried to use the if tin but I get an error message. Can anyone let me know how to modify dates so the X axis starts from Mar 2003 and goes until Mar 2008 as my data suggests?
. tsset mdate mdate, format(%tmMon_CCYY)
panel variable: mdate (weakly balanced)
time variable: mdate, Mar 2003 to Mar 2008
delta: 1 month
tab mdate
mdate | Freq. Percent Cum.
------------+-----------------------------------
Mar 2003 | 1 1.64 1.64
Apr 2003 | 1 1.64 3.28
May 2003 | 1 1.64 4.92
etc...
etc......
Jan 2008 | 1 1.64 96.72
Feb 2008 | 1 1.64 98.36
Mar 2008 | 1 1.64 100.00
------------+-----------------------------------
Total | 61 100.00
. twoway (tsline Women) (tsline Men) (tsline child), title(Women Children and Men,size(small)) note(Source: IBC , size(vsmall)) if tin(Mar 2003, Mar 2008)
option if not allowed
r(198);
thanks in advance,
Gaby
----------------------------
Gaby Guerrero Serdán
Department of Economics
Royal Holloway, University of London
TW20 OEX
Egham, Surrey
England, UK
http://www.rhul.ac.uk/Economics/For-Staff/postgrads.html
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/