LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

comparing rows of 2 different files

LABVIEW 8.5

 

Hi,

 

thought my prog would work excellent now, but there´s a little thing i do not really understand and i don´t know what i should change....

I´ve got a 4Hz (GIL) File and a 1Hz (GPS) file. Now it looks like this (Time values are red):

 

4 Hz Data                                         1 Hz Data

    0.0,-012.96,+000.53,00                  1.30, 82800,  49.016503,   8.437605,  13.48, 231.18  

    0.3,-013.21,+000.30,00                  2.30, 82801,  49.016426,   8.437457,  14.01, 231.91
    0.5,-013.33,+000.33,00
    0.8,-013.51,+000.31,00

    1.3,-013.70,+000.26,00      <-----VALUE MISSING (3 values instead of 4)
    1.5,-013.81,+000.27,00
    1.8,-014.00,+000.21,00
    2.0,-014.26,-000.30,00
    2.3,-014.39,+000.17,00
    2.5,-014.61,+000.23,00
    2.8,-014.66,-000.01,00

 

In this VI i told the prog, to write each row of 1Hz-data as often as 4Hz-data´s rows after comparison of INTEGER TIME VALUES.

After comparison now there is

 

    1,-013.70,+000.26,00,  82800,49.016503,   8.437605,  13.48, 231.18

    1,-013.81,+000.27,00,  82800,49.016503,   8.437605,  13.48, 231.18
    1,-014.00,+000.21,00,  82800,49.016503,   8.437605,  13.48, 231.18
    2,-014.26,-000.30,00,   82801,49.016426,   8.437457,  14.01, 231.91
    2,-014.39,+000.17,00,  82801,49.016426,   8.437457,  14.01, 231.91
    2,-014.61,+000.23,00,  82801,49.016426,   8.437457,  14.01, 231.91
    2,-014.66,-000.01,00,   82801,49.016426,   8.437457,  14.01, 231.91

 

But there is a mistake. Please take a look at the picture below to understand the mistake, it would be too long to describe it....There is a TimeValue missing in 1Hz Data (it should be 69611,69612,69613 ...but it is 69611,69613 ). Because of that everything that follows is wrong...

 

Actually i just wanna tell the prog: 1) compare integer values of time, 2) now write each row of 1Hzfile to the corresponding row of 4Hzfile, 3) and if timevalues are missing (maybe from both files?), delete them...

 

Step 3 is missing...and I must tell you, that someone helped me for this VI, so it´s not really my work :(....i did not really understand all of this, so that i can not do this change on my own after a few tryings...

 

I would be grateful, if someone could take a look at it

 

Download All
0 Kudos
Message 1 of 5
(2,748 Views)
You could try to do your own homework, you know.
0 Kudos
Message 2 of 5
(2,726 Views)

It´s not homework, that was an ironic joke...I´m a LV-beginner and if things are getting more complex my brain says "ciao"....

If i knew how to do that i wouldn´t ask here, i hope this is really the last thing!! My MainProg is a big mama and everytime i think it is the last thing a new problem appears...some things are easy to solve for me....sometimes it drives me so crazy, if not....

0 Kudos
Message 3 of 5
(2,714 Views)

huhu, hello and peaceSmiley Happy...

 

looks like everyone thinks now, he would do my homework, if he would answer....

here´s a version of mine, but it doesn´t work correctly....that´s why i did not upload it....

maybe somone can lend me a hand for my "homework"if he knows a good method for solution....?

 

greetings,

lecojon

 

PS: it´s not homework...in which school do you learn LV and get homework?i don´t know any...i´m about to learn LV

In other Languages i could solve this problem easily just by writing

 

"if (timeGPS==timeGIL) then

tralala

end if " .....and it worked.. maybe there´s a similar solution method with math script in LV?*don´t know*

0 Kudos
Message 4 of 5
(2,681 Views)

....i should learn how to edit a message....

....here´s the V...oops

0 Kudos
Message 5 of 5
(2,679 Views)