-2

Below is the a small view of the file I would like to convert into a data frame but i am un sure how to do so. The data is time dependent and i am to extract statistical time features from the data. I not very good at python so just wanted to know if anyone can help out. I tried using pd.csv_read but it did not work.

### file starts from here
Data info
File name: D:\Share\20190418 - Baseline test Nu2\20190418 BaselineTest_0000.dxd
Start time: 18/04/2019 08:58:48.000
Number of channels: 16
Sample rate: 100000
Store type: fast on trigger


Data1

Time (s)    SG_Outer_L (um/m)   SG_Outer_R (um/m)   SG_Hous_1 (um/m)    SG_Hous_2 (um/m)    Temp_Oil in (°C)    Temp_Oil out (°C)   Acc_horizontal (g)  Acc_vertical (g)    Temp_Lager 1 (°C)   Temp_Lager 2 (°C)   Temp_Lager 3 (°C)   Oil_flow_rate_10 (l/min)    Axial_load (N)  Radial_load (N) Cage_Speed (V)  Shaft_Speed (V)
0       -0.0068270117   0.031498194 0.015425649 0.0081171542    64.978195   62.291813   2.6422348   -5.608747   72.961945   2586.0647   2586.0647   0.78165096  1369.7631   242.88226   5.0014362   7.4735909
1E-5    -0.0073644072   0.031504273 0.017687764 0.0081018955    64.978195   62.284924   2.6433446   -5.5246129  73.38121    2586.0647   2586.0647   0.78043807  1371.8307   242.89799   5.0014663   7.3899431
2E-5    -0.0085513741   0.031825662 0.016042795 0.0080183297    64.981102   62.275719   2.6506128   -5.513145   73.893578   2586.0647   2586.0647   0.77893639  1372.2308   242.94258   5.0013895   7.2960548
3E-5    -0.0086480528   0.031876445 0.017976012 0.0084936172    64.992264   62.273884   2.6302221   -5.5842891  73.762863   2586.0647   2586.0647   0.78025234  1369.4431   242.67818   5.0014  7.1909947
4E-5    -0.0086286217   0.032107234 0.016237702 0.0077844411    65.007309   62.275791   2.6386025   -5.5736065  73.516548   2586.0647   2586.0647   0.78200996  1373.3425   242.85245   5.0014629   7.073348
5E-5    -0.0095008761   0.031255722 0.018005576 0.00771375      65.024422   62.273144   2.6050999   -5.631999   73.183296   2586.0647   2586.0647   0.78379929  1370.1801   242.6796    5.0013704   6.9421921
6E-5    -0.010682955    0.031410575 0.01696023  0.0076747686    65.026711   62.267639   2.5763896   -5.6127739  73.090805   2586.0647   2586.0647   0.7824437   1370.6685   242.61665   5.001359    6.7960019
7E-5    -0.01044561     0.031275749 0.017342892 0.0076773912    65.026405   62.257004   2.6531544   -5.5542912  73.434235   2586.0647   2586.0647   0.78043807  1372.9846   242.73277   5.001399    6.6338596
8E-5    -0.011554852    0.030923724 0.017254915 0.0082156211    65.021851   62.24482    2.6605763   -5.5569386  73.518707   2586.0647   2586.0647   0.77988541  1368.8831   242.47003   5.001389    6.4542885
9E-5    -0.012163892    0.03091228  0.016460028 0.0073091537    65.033676   62.243988   2.614291    -5.5779767  73.431458   2586.0647   2586.0647   0.78092957  1372.3529   242.56969   5.0013461   6.2561054
0.0001  -0.012650505    0.031512976 0.018260445 0.0075946599    65.038277   62.239384   2.6102796   -5.6011024  73.344215   2586.0647   2586.0647   0.78180385  1371.2454   242.51366   5.0013571   6.0381708
0.00011 -0.013093844    0.032302618 0.017233219 0.0077930242    65.052727   62.236786   2.6299396   -5.5515862  73.609955   2586.0647   2586.0647   0.78288198  1369.8052   242.3196    5.0013161   5.7990427
0.00012 -0.014106408    0.031403065 0.018840875 0.0076655895    65.055557   62.229443   2.6078358   -5.566566   73.103142   2586.0647   2586.0647   0.78313679  1373.0814   242.49458   5.0013118   5.53794
0.00013 -0.013847843    0.03197372  0.016098227 0.0075721294    65.057281   62.218475   2.6066508   -5.5958104  73.260979   2586.0647   2586.0647   0.78193635  1369.0809   242.239 5.0013323   5.2536101
0.00014 -0.014797106    0.031957388 0.019053426 0.0075464994    65.050819   62.208843   2.6366165   -5.5566993  73.292732   2586.0647   2586.0647   0.78014022  1371.717    242.26141   5.001359    4.9447308
0.00015 -0.015255347    0.032333732 0.016939726 0.0069677383    65.050888   62.199688   2.6564231   -5.5564809  73.660515   2586.0647   2586.0647   0.78051394  1371.8812   242.30457   5.0012894   4.6104355
0.00016 -0.015934125    0.032308817 0.019215669 0.0078609735    65.051773   62.190773   2.6778057   -5.5123353  73.295815   2586.0647   2586.0647   0.78107792  1368.403    242.07306   5.0012798   4.2496986
0.00017 -0.016212001    0.03265214  0.01707324  0.0076897889    65.06131    62.186646   2.6274028   -5.5611897  73.272079   2586.0647   2586.0647   0.78263283  1373.052    242.20992   5.0013247   3.864028
0.00018 -0.016418234    0.033141613 0.018270817 0.0079661161    65.06662    62.176872   2.5998559   -5.6419849  73.134583   2586.0647   2586.0647   0.78262943  1369.5863   242.09857   5.0013113   3.4664674
0.00019 -0.017450467    0.032771468 0.019201484 0.0068022758    65.056206   62.165474   2.6255944   -5.5718565  73.305992   2586.0647   2586.0647   0.78106433  1370.4032   241.95599   5.0012178   3.0799
ocrdu
  • 2,172
  • 6
  • 15
  • 22

1 Answers1

0

Strip everything from the file but the data (so remove metadata, column headers, etc.) and try reading with an extra option:

pd.read_csv('foofile', sep='\s+', engine='python')

This will treat whitespace (spaces, tabs) as a separator.

ocrdu
  • 2,172
  • 6
  • 15
  • 22