How do I convert a 1-D array of cluster of 5 elements into a 2-D array of numbers? (history data from a chart)

Hello,
in my vi I have a chart with 5 Plots displaying measurement data.
The user should be able to save all the history data from the chart at anytime. (e.g. the user watches the chart and some event happens, then he presses a "save"-button)
I know, that I can read out the history data with a property node. That is not the problem. The problem is, how do I handle the data? The type of the history data is a 1-D array of cluster of 5 elements.
I have to convert that data somehow into a 2 D-array of numbers or strings, so that I can easily save it in a text-file.
How do I convert a 1-D array of cluster of 5 elements into a 2-D array of numbers?
I use LabVIEW 7.1
Johannes
Greetings Johannes
Using LabVIEW 7.1 and 2009 recently
Solved!
Go to Solution.

Gerd,
thank you for the quick response and the easy solution.
Look what I did in the meantime. I solved the problem too, but muuuch more complicate :-)
And I have converted the numbers to strings, so that I can easily write them into a spreasheet file.
Johannes
Message Edited by johanneshoer on 04-28-2009 10:39 AM
Greetings Johannes
Using LabVIEW 7.1 and 2009 recently
Attachments:
SaveChartHistory.JPG ‏57 KB
SaveChartHistory.JPG ‏57 KB

Similar Messages

  • How do I convert psd to jpg on an IMac using PS Elements?

    How do I convert psd to jpg on an IMac using PS Elements?

    Nonamesleft a écrit:
    How do I convert psd to jpg on an IMac using PS Elements?
    If you are editing a single psd file in the editor, simply choose 'save as' and specify the jpg format in the save dialog.
    If you want to batch convert many psd to jpg in the editor, use the 'File/process multiple files' command.
    If you are in the organizer, use the export function and select the jpg format in the export dialog.

  • How do I convert pdf files provided to me on disc in discovery into searchable pdf files?

    How do I convert pdf files provided to me on disc in discovery into searchable pdf files?

    Rick Borstein's Acrobat for Legal Professionals blog can help you with this.

  • How can I write a 1d array of cluster with 3 elements to a file?

    Hi,
    I have to make a "Power spectral densities" analyse from my waveform data. The results from this VI is an array of cluuster with 3 elemments. Now I want to write this array of cluster with 3 elements to a file. And later it must be able to use this file with EXCEL!!
    thanks

    Hello schloronzo,
    make a for loop feeded with your array. Inside the for loop unbundle
    the cluster, "format into string" the 3 values, adding the result to
    the ones before and collect them in a shift register. Then save the
    resulting string to a txt-file. If you make a good format string then
    Excel is able to read your txt-file (use tab a separator and CR/LF
    after each 3 values aka "csv format").
    Best regards,
    GerdW
    CLAD, using 2009SP1 + LV2011SP1 + LV2014SP1 on WinXP+Win7+cRIO
    Kudos are welcome

  • 1D Array of Cluster of 2 Elements Write to Spreadshee​t

    Hi all, first time using LabView in many years.  I am trying to write a VI that will acquire data from our cDAQ (right now just trying to get it to work with a single thermocouple in a NI 9211, but eventually will be 8 X thermocouple, 4 X pressure transducer), display it in realtime on a plot, and then when the acquisition is stopped, output the data to a file for later use.  I am currently using the Base LabView package.
    My problem (as I remember it was 7 years ago when I last used this) is with the data types not working together.  This is my thought process currently on building this VI.  Everything is inside a While Loop with the Wait function at 1000ms.
    - Acquire a point of data using the DAQ assistant
    - Send that point of data into a bundle
    - Send the iteration count into the same bundle (as a timestamp)
    - Send the resulting cluster of 2 elements into a Build Array function
    - Send the resulting 1D array to a shift register in the While Loop, as well as to an XY graph for realtime plotting
    - Wire the incoming point on the shift register back into the Build Array function
    In my mind, this allows the XY graph to plot the complete array every iteration, giving a realtime view of the signal.  Everything works fine up to this point.  My problems are:
    When I stop and restart the program, the shift register is not cleared, so the existing data in the array remains on the graph.  I know I need to initialize the shift register to clear it, but I cannot figure out what to wire to it that will be compatible with the data type (I just get broken wires with everything I tried).
    Similarly, I cannot figure out how to output this data to a spreadsheet after I Stop the While Loop.  I think I should wire the "Write to Spreadsheet File" VI to the outgoing shift register, but again, I can't get compatibility with data types (source is a 1D array of cluster of 2 elements).
    I have attached my current program "Production" to this post.
    I look forward to the help!
    Brad
    Attachments:
    Production.vi ‏46 KB

    Hi Brad,
    I would suggest you change your architecture. First, to answer your questions:
    1.
    In order to ensure that your shift register is not reading the last
    value from it's memory location, you just need to create a constant for
    the shift register. To do this, right-click at the input of the
    'left-placed' shift register and create a constant.
    2. The Write
    to Spreadsheet is expecting a 1-d or 2-d array while you are wiring a
    Dynamic Data Type. Use the Convert from Dynamic Data Type to convert
    the data into the appropriate waveform after which you can get the
    waveform attributes which includes the values and the timestamp data. Or, you can use the Write to Measurement File to write to a .lvm file which can be opened in Excel as well.
    Changes to your architecture:
    Since
    you are using a lot of channels, I would advise you use a
    producer/consumer architecture. You can have a look at this
    architecture by navigating to File -> New.. and searching for the
    Producer/Consumer template. You will notice that this architecture uses
    queues. The way you will design your VI is to use DAQ to acquire the
    data into your producer loop, convert this data into a waveform and
    then send this data to the consumer loop via queues. In your consumer
    loop, you can write this data to a file. At this point, I would
    encourage you to write to a binary file instead of a spreadsheet file. The write will happen faster and you will be using less space on your hard disk when compared to ASCII writes.
    I know this can be real confusing for a beginner, so be sure to post back if you have any questions.
    Adnan Zafar
    Certified LabVIEW Architect
    Coleman Technologies

  • How to extract the data from the chart. Data were not saved

    Hi everyone. Beginners question, but could not find an answer to it
    How can I get the numerical data from the chart. Chart is already on the screen and data vere not saved into file during VI run. All I have - just chart, but I need numbers       
    Thanks
    Message Edited by olka on 07-18-2007 09:41 AM

    You can still do it, the process just changes a bit...
    Copy the control to a new VI as before, and change it into a control.
    Create the diagram shown in the attached screen shot.
    Run the new VI. You will get two arrays: one of x-axis values and one of y-axis values.
    Mike...
    Message Edited by mikeporter on 07-18-2007 12:21 PM
    Certified Professional Instructor
    Certified LabVIEW Architect
    LabVIEW Champion
    "... after all, He's not a tame lion..."
    Be thinking ahead and mark your dance card for NI Week 2015 now: TS 6139 - Object Oriented First Steps
    Attachments:
    extracting xy data.JPG ‏5 KB

  • Connect 1 D array of cluster of 2 elements with dynamic data

    Hello
    The type of source is 1D array of cluster of 2 elements and the type of sink is dyanamic data. Can any one guide me how to connect these 2 elements together. Any response would be highly appreciated. 
    Thanks 

    First, this question would more appropriately be posted to the LabVIEW Board. It is not a signal conditioning issue.
    The dynamic data type (DDT), sometimes referred to as the "evil dynamic data type," completely obscures the internal data structure. The only way someone could help is if you tell us what the source is expecting the internal data structure to be. The only objects which want DDT inputs are Express VIs, which are also good at obscuring thier contents. Implementing the sampe funcitonality with standard VIs might be a better approach.
    You also have not completely specified the source. What are the data types of the cluster elements? 
    Lynn

  • TS4036 I added Icloud to join my calendar to another person. It erased all history date from previous months. how do I get that data back?

    I added Icloud to join my calendar on my phone to another person. It erased all history date from previous months. how do I get that data back?

    i found the answer to the first part: reboot and keep hold of command+r
    this gave me a list of options
    one of them was to reinstall lion from fresh
    i went for this
    dont know why... but all forum posts i read said u should delete hard disc? theres an option for this
    which is the right option?
    any suggesstion where i go to register new mac would be great
    thanks

  • Write an 1d-array of cluster with 3 elements

    Hi,
    I have to make a "Power spectral densities" analyse from my waveform data. The results from this VI is an array of cluuster with 3 elemments. Now I want to write this array of cluster with 3 elements to a file. And later it must be able to use this file with EXCEL!!
    thanks

    Hi
    I found some outer Forum entries about this topic.
    Look at this links:
    http://forums.ni.com/ni/board/message?board.id=170&message.id=49553&requireLogin=False
    http://forums.ni.com/ni/board/message?board.id=170&message.id=51526&requireLogin=False
    I hope this helps
    Manuel

  • Write 1d array of cluster with 2 elements to file

    HI!
    I'm new at LabView so I hope the question is very simple to you:
    I am using a waveform graph to display several measurements.
    Now I want to save these Measuremens. The data are stored in 1d array of cluster with 2 elements.
    What is the easiest way to do this??
    Thanks

    If you are already using waveforms you can simply wire right up to "Write Waveforms to File.vi" in the Waveform palette under Waveform File I/O.
    Daniel L. Press
    PrimeTest Corp.
    www.primetest.com

  • Saving data from 1d array of cluster of 2 elements: HP 8752 driver

    I'm using the following driver to communicate with my HP 8720C Network Analyzer
    http://sine.ni.com/apps/utf8/niid_web_display.down​load_page?p_id_guid=E3B19B3E9092659CE034080020E748​...
    ...So far I've easily been able to use the "collect and display data" vi, except for saving data. All I want to be able to do is save the data from a single sweep in spreadsheet format. Displaying the data is no problem, which I can then print, however, the output data file is a mess. The VI is rather complicated, and I can't figure out how to save the data in a nice pair of columns of numerical values.
    The VI's output data is in the format of a 1 dimensional array of clusters of 2 elements (ie the x-y values). I would've thought it would be trivial to do this, since this is the standard format for data for the classic X-Y graph. So far, I haven't been able to come up with anything. Any ideas?
    Thanks,
    Spence

    Feed the array of clusters into a for loop with autoindexing enabled (the default). Inside the loop use the Unbundle primitive to extract X and Y for one point. Use Build Array to make a two-element array from X and Y. Wire this array out of the for loop and you will have a two dimensional array with two columns and as many rows as there are elements in the array of points.
    Lynn

  • I would like to place an element into a two dimensional array, and I would like to be able to specify which row and column each of the elements will go in.

    In the vi that I am writing I have rise and fall times to post in a very specific pattern. I can initialize an array,and I can replace elements, but in "replace element" I only find that I am given the choice of specifying a single dimensional position. I need to be able to specify BOTH column and row. Can anyone help me?

    Hi Jryan !
    If you wire a 2D array to the input of a "replace element" function, you will see that the function expand to display an additionnal index. The one you are looking for !!
    Chilly Charly    (aka CC)
             E-List Master - Kudos glutton - Press the yellow button on the left...        

  • Adding an element in an array of cluster of 2 elements

    Hi all,
    I have a 1D array containing a cluster of 2 numeric elements (= 2 rows of 100 values).
    From this array, collecting new data in for loop, I want to create another array containing a cluster with 9 elements: in each for I want to add an element (= like one row).
    After this, I want to compare data from one element with a fixed value, and when the value is find in the element, I want to extract the values of the 8 other elements at this point.
    Thanks
    Dze

    Sorry I didn't understand you well. To use only arrays, you'll need 3D arrays, as you can see in the example attached. I've made two variants, one with your method (don't know if there's an easyer one) and one with the method I think is easyer, after that, you can search in the 3D array easyer that in the array of clusters of arrays (uff...). If I misanderstood you again, please let me know.
    Hope this helps
    Attachments:
    arrayclusterarray.llb ‏50 KB

  • Connect an 1-D array of cluster of 3 elements with dynamic data

    hi everybody.
    I am trying to wire an 1-D array which consists of a cluster of 3 elements with dynamic data. The error that appears says that I'm trying to "connect two terminals of different types". Actually, what I want to do is write to a file the FFT data produced by the Spectral Measurements vi. In order to write to a file, I am using the Write to Measurement File vi, but I don't know if this is the right way to do this. Has anyone any idea about this problem, because I'm out of ideas....
    Thanks a lot!!

    ok! This works really good! thanks a lot! now i'm facing an other problem...The output file does not contain the right data. I want to collect the FFT (frequency vs. amplitude) of a time signal and it gives me the record length and the sampling rate instead.
    For example, if I use a sampling rate of 300 ksamples/sec and a record length of 1000 sampling points, the file to be created has one column containing the record length e.g.
    0
    1
    2
    3
    498
    499
    and on more column containing almost zero values and the value of the sample rate. Do you have any idea why this is happening?
    Thank you!!

  • How do you convert a Photoshop Album 2.0 catalog to Photoshop Elements 13.0 catalog?

    I have a lot of photographs with metadata and tags in Photoshop Album version 2.0 and I want to pull thee images, metadata, and tags into Photoshop Elements version 13.0 on a Windows 7 computer. Searching the web I found that this has to be done with the convert feature.  I tried File, Manage Catalogs, Convert and point to the folder holding my Photo Project Catalog.psa file, but nothing happens. It does not apparently see the .psa file.  How do I get my .psa catalog migrated into Elements 13?

    Hi,
    See if this helps.
    Convert Organizer catalogs for 64-bit versions | Photoshop Elements 13 or later
    Brian

Maybe you are looking for

  • Connecting to db2 from report builder via odbc

    Hi! Some manuals said, it is possible to connect to DB2 from Oracle SQL*Plus (we have version 8.0.6.0.0) and from Oracle Report Builder.(6.0.8.11.3) User must install OCA (Oracle Open Client Adapter for ODBC (6.0.5.29.0)) and make ODBC entry. I did i

  • Trouble using sound effect samples in Logic 7.2.3

    I'm using a Mac book Pro (10.4.11) and I've got these samples of sound effects (aiff format) that I want to triger with the Ultrabeat plug in. the built in samples that come with Logic (in the loop browser) work just fine. but when I try to load a th

  • My email was deleted and I've forgotten my skype p...

    I'm not sure if this is an extremely unique problem but it's fairly irritating. Yahoo deleted the email account I used to sign into Skype and it created no problems till I forgot my password. It was my first email account and I hadn't touched it in y

  • What are the odds of GTA coming to Mac for computer games?

    Just wondering if there's any chance of Grand Theft Auto computer games coming to Mac. Thanks

  • Slow speeds for the past 2 weeks

    For the past 2 weeks I have been having very slow speeds. At first I thought it was the westell modem which kept powering down, rebooting every 30+ mins or would save the network settings. Purchase a new modem still have the slow speed minus the cons