python-read multiple files and write
<p>I have 2 sets of files. One starts as:sinu_bh8_np...dat, and the other as: sinu_bh9_np...dat. Each set has say, 3 files.</p>

<p>The first four lines in each file have some text (which is to be ignored), follwed by data in 2 columns.</p>

<p>The number of lines in the files are not equal.</p>

<p>I need to read one set of 3 files at a time (ignoring the first 4 lines in each file).</p>

<p>Say, the data is X1(i), Y1(i) in file1, X2(i), Y2(i) in file2 and X3(i), Y3(i) in file3.</p>

<p>When I write data, I want that to be X1(i), Y1(i), Y2(i), Y3(i)  (i.e. 1st column of the 1st file vs 2nd column of all the three files).</p>

<p>I have actually a large number of files to be merged this way. So, is there any good way to achieve this in python scripting or something of that sort?</p>

<p>Thanks in advance!!</p>
