title: R - Reading lines from a .txt-file after a specific line
body: <p>I have a bunch of output .txt-files that consists of a large parameter list and a X-Y-coordinate set. I need to extract these coordinates from all files so that only those lines are imported to a vector. This would work fine with</p>
  
  <pre><code>impcoord&lt;-read.table("file.txt",skip= ,nrow= ,...)
  </code></pre>
  
  <p>but the files print the coordinate sets after different lengths of supporting parameters.</p>
  
  <p>Luckily the coordinates always start after a line containing certain words.</p>
  
  <p>Thus my question is, how do I start reading the .txt-file after these words? Let's say they are:</p>
  
  <pre><code>coordinatesXY
  </code></pre>
  
  <p>Thanks alot for your time and help!</p>
  
  <p>-Olli</p>
  
  <p>--Edit--</p>
  
  <p>Sorry for the confusion.</p>
  
  <p>The part of the file is as follows:</p>
  
  <pre><code>##XYDATA= (X++(Y..Y))
  131071    -2065
  131070    -4137
  131069    -6408
  131068    -8043 
  ...       ...
  ...       ...
  </code></pre>
  
  <p>The first line being the one where <code>skip</code> should end and the following coordinates need to be imported to a vector. As you can see the X-coordinates start from 131071 and end to 0.  </p>