Hi everybody,

I am using Stata15 and want to show oil price development in the time-period I am looking at since its part of my independant variable.

Code:
* Example generated by -dataex-. To install: ssc install dataex
clear
input int id_2 long yrmo int target_sidea double oil_price_t0 float OPS_t
. 200312   .  27.85            .
. 200912   .  75.48            .
. 200304   .  23.43            .
. 200907   .  64.96            .
. 200305   .  24.25            .
. 200905   .  57.39            .
. 200401   .  28.68            .
. 200906   .  69.21            .
. 200307   .  26.62            .
. 200303   .  27.42            .
. 200311   .   27.5            .
. 200309   .  25.26            .
. 200302   .  30.19            .
. 200908   .  71.32            .
. 200911   .  77.62            .
. 200308   .  27.61            .
. 200310   .  27.13            .
. 200306   .  25.49            .
. 200910   .  73.27            .
. 200903   .  45.57            .
. 200904   .  50.18            .
. 200301   .  28.05            .
. 200909   .   67.9            .
1 200806  27 127.58    .07012443
1 200709  57  73.25    .08620504
1 200405  35  34.47    .10416858
1 200803  28  96.77    .07297191
1 200511  76  51.31   -.04478218
1 200605 221   64.9   .013183548
1 200606 128  65.08   .002769635
1 200802  37  89.96   .031504914
1 200510 105  53.66   -.05228052
1 200609 184  59.77   -.14040913
1 200901  18  44.96    .09244503
1 200807  21 131.22    .02813167
1 200406  52   33.4  -.031533517
1 200702 185  55.68    .06818504
1 200503 118  45.57     .1073863
1 200608 149  68.78  -.003773055
1 200407  54  34.48     .0318235
1 200610 245   56.5   -.05626323
1 200509  96  56.54 -.0014139086
1 200404  43  31.06     .0195065
1 200801  42  87.17    .01642415
1 200811  34  51.38   -.28933507
1 200410  87  37.57    .05751856
1 200701 216  52.01   -.12032206
1 200703 139  59.05    .05876352
1 200412 107  34.26  -.017648337
1 200808  36 113.21   -.14763081
1 200501 162  37.81    .09859517
1 200812  39  40.99   -.22592087
1 200602 145  57.57   -.01277203
1 200707 114  69.45     .0547474
1 200409  12  35.47   -.07650152
1 200505 179     45   -.04561048
1 200508 112  56.62    .06890459
1 200611 136  56.81   .005471728
1 200704 186  63.83    .07783877
1 200804  30 103.46    .06684807
1 200607 172  69.04    .05906874
1 200403  32  30.46     .0703774
1 200604 180  64.05    .10544727
1 200603 138  57.64  .0012151777
1 200506 122  50.97    .12457474
1 200512  29  53.12   .034667812
1 200902  18  43.13   -.04155437
1 200402  14  28.39  -.010163056
1 200507 117  52.85   .036220465
1 200411 231  34.87     -.074579
1 200504 123   47.1   .033023402
1 200706 108  65.75    .01857447
1 200809  30  95.96   -.16531305
1 200810  31  68.62    -.3353474
1 200711  52  86.73     .1171779
1 200601 163  58.31    .09322012
1 200805  32 118.94    .13943411
1 200712  57  85.75  -.011363798
1 200612 124  58.66   .032045674
1 200502 101  40.93    .07928964
1 200408  78  38.29    .10480934
1 200705 123  64.54   .011061858
1 200710  45  77.14     .0517437
1 200708  77   67.2   -.03293378
2 200601 293  58.31    .09322012
2 200604 208  64.05    .10544727
2 200509 185  56.54 -.0014139086
2 200512  75  53.12   .034667812
2 200703 339  59.05    .05876352
2 200610 378   56.5   -.05626323
2 200902  16  43.13   -.04155437
2 200808  29 113.21   -.14763081
2 200510 295  53.66   -.05228052
2 200708 199   67.2   -.03293378
2 200607 278  69.04    .05906874
2 200612 350  58.66   .032045674
2 200704 360  63.83    .07783877
2 200806  48 127.58    .07012443
2 200609 302  59.77   -.14040913
2 200506 149  50.97    .12457474
end
format %tm yrmo


The data is correctly xtset:
Code:
xtset id_2 yrmo, monthly
And I want (for starters) a simple graph:
Code:
xtline oil_price_t0, overlay
After all I have read this should work, but it doesn't and Stata gives me a 'invalid syntax'.

I'd appreciate any hint.
Best
Marvin