title: Parsing a log file into CSV format
body: <p>Im trying to develop a small bit of code that will help me delimit a log file that has stored a large number of trace routes to different IP's that were sent over a period of week.</p>
  
  <p>Im hoping to split them using a '--- START ---' and '--- END ---' tag at the begining and the end of each trace route. Example is as followed:</p>
  
  <pre><code>--- START ---
  Mon Mar 12 22:45:05 GMT 2012
  traceroute to xxxxxxx (xxxxxxxx), 30 hops max, 60 byte packets
  1  xxxxxxx (xxxxx)  1.085 ms  1.662 ms  2.244 ms
  2  xxxxxxxx (xxxxxxx)  0.792 ms  0.782 ms  0.772 ms
  3  xxxxxxxxx (xxxxxxxxx)  8.545 ms  9.170 ms  9.644 ms
  4  etc
  5  etc
  --- END ---
  --- START ---
  Mon Mar 12 22:45:05 GMT 2012
  traceroute to xxxxxxxxx (xxxxxxxx), 30 hops max, 60 byte packets
  1  139.222.0.1 (xxxxxxxxx)  0.925 ms  1.318 ms  1.954 ms
  2  10.0.0.1 (xxxxxxxx)  0.345 ms  0.438 ms  0.496 ms
  3  172.16.0.34 (xxxxxxxxx)  0.830 ms  2.553 ms  0.809 ms
  4 etc
  5 etc
  6 etc
  --- END ---
  </code></pre>
  
  <p>Can anyone give me a hand into how this would be done, in matlab or java... I'm also trying to count the amount of hops each trace route makes. That being the number given before the --- END --- tag is thrown...</p>
  
  <p>Any help would be greatly appreciated, </p>
  
  <p>Cheers.</p>