キャンセル
次の結果を表示 
次の代わりに検索 
もしかして: 

Average Data

解決済み
解決策を見る

What I want:

 

I want to have a numeric control that controls the amount of data that will be averaged.

(ex: numeric control set to 10)

This control results in the 10 data points before and the 10 data points after the current iteration will be averaged

 

My guess at a solution:

 

The numeric control will be combined with the iteration in a for loop.

My array of data will enter this for loop and combine with this.

My output of the for loop will be the averaged data.

I will then delete the first 10 lines of the array but I can do that.

 

An example vi of this would be awesome, I figured it will take someone no time at all to implement this.

 

Thanks!

 

Christian

0 件の賞賛
メッセージ1/20
5,384件の閲覧回数

Hi cseymour,

 

this really sounds like homework. The usual reply for homework is:

Start to code on your own. Then attach what you have achieved so far and ask for specific problems of your code…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 件の賞賛
メッセージ2/20
5,375件の閲覧回数

If only it was homework.....

 

It's for a senior project that I have been working on, I am novice to many aspects of LV since was just introduced to it a month ago.  Right now my mind is running in circles so that's why I need help. But I'll attach the subvi that I have that I will implement this in.

 

Long story short, I have IMU data that has already been saved to a tdms file. I am pulling the separate waveforms out and I simply want to cancel some noise out and smooth the data. I want to average it as I posted above.

 

The vi is really a mess right now so dont be shocked.

 

Thanks!

Christian

0 件の賞賛
メッセージ3/20
5,365件の閲覧回数

Hi cseymour,

 

have a look at PtByPt-Mean and try to use that on one of your waveforms…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 件の賞賛
メッセージ4/20
5,360件の閲覧回数

Yes I have looked at it.

 

What it does is take your sample length and use the previous values to find the mean.  

 

I want to use the previous and future values to find the mean.

 

Thanks,

Christian

0 件の賞賛
メッセージ5/20
5,353件の閲覧回数

How is the program supposed to predict the data from the future?

0 件の賞賛
メッセージ6/20
5,349件の閲覧回数

I have already collected all the data and now i am running it through post-processing.

 

Thanks,

Christian

0 件の賞賛
メッセージ7/20
5,342件の閲覧回数

OK, so this is a trivial problem. Can you attach some typical data?

 

 

0 件の賞賛
メッセージ8/20
5,335件の閲覧回数

File attached. Is that what you want?

 

Thanks,

Christian

0 件の賞賛
メッセージ9/20
5,324件の閲覧回数

@cseymour05 wrote:

I have already collected all the data and now i am running it through post-processing.


No, don't flood us with tons of irrelevant data. Just attach the 1D array that contains the data. You also need to decide what to do with the data at the beginning and end, where the averaged subset is truncated.

0 件の賞賛
メッセージ10/20
5,319件の閲覧回数