DIAdem

cancel
Showing results for 
Search instead for 
Did you mean: 

Data reduction

I'm considering using DIAdem to process data from a third party data acqusition application that produces large data files (e.g. 100 - 240 channels @100 samples/sec for several hours). I have an evaluation version of DIAdem 9.1, and I was able to import such a file into DIAdem using a plug in. In addition to viewing data and creating reports, I would like to perform two other operations:

1. Export a block of data from a specific time window (30 to 120 seconds wide)to a new file in one or more of the following formats: Excel, ASCII, or a database file (I currently have Access and MySQL). Using the band cursor and flags in VIEW, I have created new channels that contain the data that I'd like to export. Is it possible to export these channels to a new file?

2. I'd also like to save a reduced data set to a new file (same formats as above) by exporting one out of every N points from the original data file (where N is an interval specified by the user). Is there an easy way to set this up?


Thanks for your help and for putting up with questions from a "Newbie"!

Dave Z.
0 Kudos
Message 1 of 5
(4,070 Views)
Hi Dave,

To save just a few channels (columns) of data, use the following method:

1. Select (highlight) the channels you want to store in the Data Portal.
2. Choose the "Save As..." item from the file menu.
3. Check the little box on the bottom of the dialog called "Only elements selected in the Data Portal".
4. Select your export method (CSV and LVM both produce ASCII files).

With regards to saving only one out of every N points of a data channel, there are different approaches to do that. You could use on of the curve fitting functions (i.e. Splines, where you can select the number of points that are created as the result of a calculation) and store the result data using the method described above. You could also write a small script that copies every Nth value into a new channel and then save that new channel.

To my knowledge, there is no immediate function available to do data reduction, so a small script may be the best way to go.

If you have any questions about the demo, please feel free to give me a call at (512) 683-5452.

Otmar
Otmar D. Foehner
0 Kudos
Message 2 of 5
(4,036 Views)

Dave,

I had previous built an example to perform the data reduction of every Nth point. As Otmar points out, it does have to be done in a script, but this example should simplify things for you:
Reducing a Channel in DIAdem by Pulling Every Nth Point  [link removed; example is no longer available]

If you have any questions about this, please let us know. Thanks and have a good one.

Adam B.
Applications Engineer
National Instruments

Message 3 of 5
(4,027 Views)
Hi Adam,

I assume you wrote the VBscript, which you linked to.  I have a question for you related to DataPlugins, which is mentioned in the article.

I have no experience with the DataPlugins, so please bear with me. 

From the sounds of it, the DataPlugin would associate a file format somewhat permanantly with a file extension and would always load the data per the 'Nth channel import' laid out in the VBscript/DataPlugin.   Is this true or I am misreading something?
0 Kudos
Message 4 of 5
(4,003 Views)
 

HI Rich,

Yes, that is correct.  A dataplugin allows you to associate a special VB Script to be executed every time you load a file of a specified type.  I use the word special as you will need to use the Dataplugin API to actually create the Dataplugin in VB Script.  The code that is attached in the example could certainly be utilized in the Dataplugin, but it wouldn't be as simple as copying and pasting into a seperate file.  You can find more information about Dataplugins, including the programmer's reference guide, here:

Dataplugins: Downloads and Developer Information

This site should answer most of your questions about Dataplugins, but if you have additional questions, please feel free to repost.  Thanks and have a good one.

0 Kudos
Message 5 of 5
(3,986 Views)