Reading from a .txt and displaying in XY graph with time stamp

Hi,
I am a newbie to LAbView. I need to read from a text file having two columns, one carrying the temp value and other the time stamp. I need to plot this in XY graph on a real time basis. Please help as how can I do this..
I am attaching my files for your reference.
Thanks in advance
Ratnesh

Shidla wrote:
So what is the question about... I have to use XY graph in my program. It is used in Loop while cycle. It shows the statistic of a variable. I am using cursors in this graph to check the actual value of a variable in different period of time. But there are 7 variables and it is extremely hard for user to check each value independently. So I tried to make them moving on the X axis (TIME) together using the property node (cursors reading the position (only X axis, Y axis status lock to plot) of the major cursor and follow it... Everything looks great? But it did not work when I am trying to move the major cursor manually on graph... It works only when I am using the cursor movement buttons... But they work very slowly when there is a lot of data in graph.
I want to find out is it possible to make seven coursers mouthing together By the X axe and be Locked each at its plot by Y axe manually (Using mouse moving on a graph). Is it possible? If it is than how to do it?
Hello Shidla,
The attached VI should help give you an idea of how to create a VI that allows all cursors to move together. The main idea is to keep track of the current location of all cursors and move all of them when you see a change in one's position.
Good luck with your development.
-Matt F
Keep up to date on the latest PXI news at twitter.com/pxi
Attachments:
cursors.vi ‏164 KB

Similar Messages

  • How to read time stamps from a spreadsheet and calculate the difference between consecutive time stamps?

    Hi,
    I am new to Labview. This question might be a joke to some of you here, but any help would be greatly appreciated. I have a spreadsheet with time stamps and power outputs from a generator. I am supposed to calculate the difference between consecutive time stamps, which will act as a delay for the next power output update that needs to be sent. For example, lets say that I have to following data:
    Time Stamp                    Power Output
    11:00:00 AM                       3kW
    11:00:02 AM                       2.9kW
    11:00:04 AM                       3.2kW
    11:00:06 AM                       3.1kW
    The above data doesn't make any sense, but it is just for the purpose of this question.
    So, I have to read 11:00:00 AM and 3kW initially - 3kW is the initial request that is sent. Then I have to

    Repeated forum post
    Please view http://forums.ni.com/ni/board/message?board.id=170&message.id=294435
    Regards,
    Juan Galindo
    Applications Engineer
    National Instruments

  • Read a text file and display a xy graph

    Hi!
    I am using LabVIEW 8.5, and I am trying to read columns from
    a file and plot with xy graph. I can do it with two channels, but I am having
    problems when the numbers of channels connected increase (maybe six or ten).
    My text file looks like this:
    [Where first column x = time, the rest of the columns are
    channels = y]
    8.828        22.604        23.076            [The number of channels connected can
    change]
    9.828        22.604        22.604
    10.828      21.658        22.131
    11.828      22.131        22.131
    12.828      22.131        22.131
    13.828      22.604        22.604
    14.828      21.658        22.604
    15.828      22.131        22.131
    16.828      21.658        23.076
    17.828      22.604        22.131
    18.828      22.131        22.604
    I attached a picture of what I already try… Now I am trying
    a combination of those. If anyone has some
    advice or suggestion, please let me know.
    Sincerely,
    Julieta.
    Solved!
    Go to Solution.
    Attachments:
    xygraph.PNG ‏25 KB

    Thanks for the advice!... I just modified what I had a
    little bit and it is working, maybe is not the optimums solution…
    I would like to make the time invisible in the graph… It that possible? I attached a picture of my graph, because my English is not good.  There are two lines near to 22 (two channels
    connected at that moment), and a line near to 0 which is time (the strong pink one).  I would like to make invisible the strong
    prink one only.  I try to make invisible,
    but I fail… I changed colors looking for another solution and I fail again,
    because it is taking the colors that I choose for the channels.  I can not disable because I need it to make
    the x axes works with the time that I already saved. 
    If someone has an advice or suggestion I really appreciate it…
    Sincerely,
    Julieta.
    Attachments:
    xygraph.PNG ‏9 KB

  • Read from spreadshee​t and plot multiple XY graph

    I'm trying to read a text file using the "Read from Spreadsheet" function. Next I want to plot the data in it on a single XY Graph.
    The text file contains 4 coloums and the first coloumn is X axis and rest are for Y axis. I'm not able to get the multiple plots. 
    However, I could get it to plot when only a single graph is to be plotted(only 2 coloumn in file). I've attached my VI and a picture here.
    I need help in plotting multiple XY graph from the text file with the 4 coloumns.
    Solved!
    Go to Solution.
    Attachments:
    Test_1.vi ‏13 KB

    Here's a more scalable solution, useful if you have one x and many y columns.
    LabVIEW Champion . Do more with less code and in less time .
    Attachments:
    MultiXY.png ‏5 KB
    MultiXY.vi ‏10 KB

  • Trying to read a recorded file that display the x-axis recorded time stamp?

    How do I read a recorded file with (XY) data, meaning I want to plot the x-time recorded data and be able to scroll back and forth.

    Hi Gina,
    If I understand your question correctly, it sounds like you are trying to plot some data that you have saved in a file. I am assuming that this data is in the form of X and Y values.
    If this is correct, the easiest solution would be to use an XY-Graph in LabVIEW. I would start by using LabVIEW's File I/O VIs to load the data into an array or even a string indicator. You can then parse the data that you need and separate it into two arrays, one for X values and one for Y values. You can then bundle these two arrays together and feed the resulting cluster into an XY-Graph.
    I have attached an example that may help to point you in the right direction when it comes to the actual programming.
    I hope this helps!
    Matthew C
    Applications E
    ngineer
    National Instruments
    Attachments:
    Example.zip ‏61 KB

  • How to read two text files using the Read from spreadsheet.vi and then plot it

    I need to read two text files using the read from spreadsheet function and then plot these files over time.
    The file with the .res extention is the RMS values (dt and df) and the second file contains the amplitude of a frequency spectrum.
    I really appreciate any help..thanks
    Attachments:
    RMS.txt ‏1 KB
    FREQUENCY.txt ‏1 KB

    From NI Example Finder:
    Write to Text File.vi
    Read from Text File.vi
    Jean-Marc
    LV2009 and LV2013
    Free PDF Report with iTextSharp

  • How can I read a column of numbers saved as .txt and display as a wave?

    Hi Tiano
    LabVIEW General
    Ask:
    Please enter a one-line summary of your question
    Resources
    • Technical Support
    • Development Library
    • Measurement Encyclopedia
    "data/time reading into chart"
    "In the attached file, I am trying to read the first column of data, and the next column is the value on the x-axis I want it plotted at. How do I read two columns of different data? I have looked in the books I have access to and the help within Labview but am still having trouble.
    Thank you,
    Ellie"
    data_set (Plain Text, 3K)
    -posted by Ellie on 9/11/2001
    markwysong on 9/11/2001 answered:
    "Ellie,
    The first thing you need to do is to read your file in as a spreadsheet file. Then, you display it in a chart.
    That sounds simple, but looking at your dataset, there's a few things you should know. First, the "read from spreadsheet VI" is looking for data in columns, like your data set, but columns separated by tabs. Therefore, your data must be saved that way; currently, it doesn't seem that it is. Another thing; you must skip the header portion (labels) of your file when reading.
    Next, it would be easier if your time was first, and your data was second in your columns, but that can be overcome. In the VI I am including, I have copied your data set into a file called data.txt, and I've removed the header and separated the columns with a tab. Then, I read in the data, and I break out each column so I can put the time first, and then I combine them again into a cluster so it can be displayed on an XY chart.
    Take a look!
    Mark"
    Graph data from file (Binary Executable, 20K)
    data.txt (Plain Text, 3K)
    This answer has not yet been rated.
    Rate this answer:
    Mikael Garcia on 9/11/2001 answered:
    "Ellie,
    Here is one way of doing it. Take a look at this example (compatible with LabVIEW 4.1 and up) and post comments if you need further help. Basically, I read your file as text; split it; and make use of the Spread sheet string to Array function before I plot your data. Hope this helps./ Mikael"
    ExtractAndPlot.vi (Binary Executable, 36K)
    This answer has not yet been rated.
    Rate this answer:
    Ellie on 9/12/2001 commented:
    "Thank you. I am trying to get the data from the text file into a string and am having some trouble. I am reading the file from a spreadsheet, and sending the output array to "Array to Spreadsheet String", but I'm not sure this is what I want to do. Is there another way to make an array into a string? Do I need to reformat my data?
    Can you offer me any advice?
    Thank you."
    data_1 (Plain Text, 3K)
    Mikael Garcia on 9/12/2001 commented:
    "I noticed that you changed your file format according to what was said here. Yes, this new file of yours is easier to use but your original file does not have to be changed. Take a look at this example. I now added the file-read part. It will give you a dialog to locate your data file (use this VI with your original file with the header since this VI includes a string split function). Hope this helps. /Mikael"
    ReadExtractandPlot.vi (Binary Executable, 35K)
    Niko on 9/12/2001 answered:
    "If you read this file with the "read from spreadsheet file.vi" you get you
    data in a 2-D-array. Now it is easy with array- and cluster-functions to
    handle the data the way you want.
    hope that helps, Niko"
    This answer has not yet been rated.
    Rate this answer:
    I intend to read from a .txt file that contains a column of numbers. After reading I want to display it as a waveform. In fact the numbers represent points along a waveform/graph of Flow vs. time. Thus I want to have this info in the chart or graph with flow in the y0axis and time in the x-axis. Can someone give me some detailed help please? Thank you in advance.
    Attachments:
    The_file.txt ‏18 KB

    All you have to do is use Read From Spreadsheet File.vi that's on the File I/O palette. For your example .txt, set the Transpose input to true and wire the First Row output to a waveform graph. The only problem I see is that since your file doesn't contain any sampling info, the time axis will be relative. If have that information elsewhere, then you can put a build waveform function between the read and the graph. Wire the First Row output to the Y input Build Waveform and add t0 and dt values. I've attached an example.
    Attachments:
    Graph_from_text.vi ‏29 KB

  • Help! Read raw Image data from a file and display on the JPanel or JFrame.

    PLEASE HELP, I want to Read Binary(Raw Image)data (16 bit integer) from a file and display on the JPanel or JFrame.

    Hey,
    I need to do the same thing. Did you find a way to do that?
    Could you sent me the code?
    It's urgent, please.
    My e-mail is [email protected]

  • Efficient optimized way to read from serial port and GPS data display using map

    Hi,
    I have a custom h/w which reads the data from GPS Rx and after parsing send it to PC over RS232.
    Each second it sends 201 bytes to PC. I have developed a VI to read the GPS data and display it. Project file is attached.
    Fulctionality of different loops are as following:
    1. LOOP 1: 1.1 Reads the serial data from com port.
                   1.2 Synclonize the frame using start bytes "a" and "z".
                   1.3 Reads next 4 bytes containg receiving error information.
                   1.4 Reads next 195 bytes. in which initial 80 byes are GPS data. rest are others.
    2. LOOP 2: 2.1 Extarcts the GPS information and put them in an array.
                      2.2 Extarcts the receive error infor and counts the total error by incrimenting the variable using shift reg.
    3. LOOP 3:3: 3.1 Displays the GPS data in chart and log the data in a file.
    4. FLOW : Uses the GMAP .NET based API to creat a MAP and display.
    Problem statement:
    1. Functionality acheived.
    2. However in between data set is being missed by the programm. 
    Quesitions:
    1. Is the developed VI is efficient in terms of using queue loacl variables etc.
    2. What are the improvments I can do to solve the problem.
    Any other suggestions|
    Thank you
    jayant
    jayant
    Attachments:
    Telemetry_Receiver_v2.zip ‏3075 KB

    One of the most common problems in serial communication is the need for an adequate timing: how much time is expected your device to spend before answering? Have you put and adequate pause in your code before reading from the serial port?
    Hope this helps
    Roberto
    Proud to use LW/CVI from 3.1 on.
    My contributions to the Developer Zone Community
    If I have helped you, why not giving me a kudos?

  • Trouble reading from serial instrument and DAq simultaneously.

    Greetings,
    I am having some trouble getting my VI to read from my DAq and a serial instrument at the same time.  If I run the subVI's simultaneously (i.e. subANG is running in one window and subVEL is running in a second window) both return the proper values and behave as I would expect.  However, if I call the subVI's into a parent VI and try to run them both in the same loop structure subANG gets stuck and will not resond with a change in signal.
    I have also tried to use a stacked or flat sequence to separate out the execution of subVEL and subANG, but I still get the no response from subANG.
    The most confusing thing is that if I run Parent.VI in one window and then create a copy of subANG (call it '....-copy' or whatever) and run it in a second window, Parent.VI behaves properly and will refresh the readings as they appear in '...-copy'.
    I have attached 3 files.
    (1) subANG.VI     -This reads an RS232 signal from an inclinometer.  The signal is refreshed every 10ms or so.
    (2) subVEL.VI      -This reads raw voltage from one channel on the DAq, calculates the mean then converts that into a pressure differential and finally a velocity based on the pressure and temperature inputs. 
    (3) ParentVI.VI     -This simply calls and displays the subVI's
    My guess is that it is a buffer issue, but I am stumped.  Does anybody out there in Labview land know why this might be happening?  All suggestions welcom.
    Solved!
    Go to Solution.

    I am noticing it is not an NI DAQ card.  How are you communicating with the DAQ? If it is using a serial port, that could be your problem.
    I also highly recommend using the VISA drivers for serial communications instead of the serial.llb VIs.
    There are only two ways to tell somebody thanks: Kudos and Marked Solutions
    Unofficial Forum Rules and Guidelines

  • Is there a way to open Excell file from the server and display in the UI and save it back on to the

    Hello there,
    Is there a way to open Excell file from the server and display in the UI and save it back on to the server? (like showing xell file as a datagrid - add rows, columns etc.)

    Hi Mike,
    Welcome you to the forum.
    You may try:
    SELECT * FROM MyDBNameHere.dbo.OUSR T0
    Thanks,
    Gordon

  • Can a servlet read a jsp file and display its contents?

    Hi,
    I would like to know if Servlets can read a Jsp file and display its contents.. Right now for our website, I am using a html file to be displayed after a successful post operation through the Servlets...
    -Thanks!

    I posted this in another thread.
    Here's some code that reads using a URL. This doesn't work with JSPs as the server executes JSP when it connects but it's useful for other file types. Note that the filename is a URI</h1>This is <code>show.jsp</code></h1>
    <hr>
    <%! String file = null; %>
    <%! java.io.InputStream is = null; %>
    <%
    file = request.getParameterValues("filename")[0];
    try {
       is = (new java.net.URL(file)).openStream();
    } catch (java.io.IOException ioe) { out.write(file + " not found!<br>"); }
    java.io.BufferedReader in = new java.io.BufferedReader(new java.io.InputStreamReader(is));
    String line = "";
    %>
    <pre>
    <%
    while((line = in.readLine()) != null) {
    %>
    <%=line%>
    <%
    %>
    </pre>

  • How to Snap/Grab Image from 1394 camera and display the Image in CWIMAQVIEWER in VC++ ?

    Hi,
    I have :  -  IMAQ1394 2.0.1
                  -  NI Vision 7.1
    In VB, I can Snap/Grab Image from 1394 camera and display the Image in CWIMAQVIEWER :
        Dim Image0 As New CWIMAQImage
        imaq1394SnapCW(sid0,Image0)
        CWIMAQViewer1.Attach Image0
    Now,How can I do this in VC++6.0?
        I tried:
                  C_CWIMAQImage m_imgViewer1;
                  m_imgViewer1 = m_CWIMAQVision1.CreateCWIMAQImage();
                  m_CWIMAQViewer1.Attach(m_imgViewer1);
                  imaq1394SnapCW(Sid,m_imgViewer1);  <--there is no "imaq1394SnapCW "function in VC++,why?
        Please help me!
        Thank you!

    For people looking back at these old posts regarding
    CWIMAQViewer - it was not made to be used in the C environments and is made
    for VB.
    Refer to the following locations for displaying images in C
    environments:
    Start»All Programs»National Instruments»Vision»Documentation
    Start»All
    Programs»National Instruments»Vision»Text Based Examples
    Make
    sure that you look at the examples and documentation that is in
    reference to the C environments not the VB environments
    Vince M
    Applications Engineer

  • I am trying to sync iphone 5 to itunes but it says "iTunes could not connect to the iphone as an error occured while reading from the device " and the iphone is not seen on itunes........

    i am trying to sync iphone 5 to itunes but it says "iTunes could not connect to the iphone as an error occured while reading from the device " and the iphone is not seen on itunes........

    First thing to try is to reset your device. Press and hold the Home and Sleep buttons simultaneously ignoring the red slider should one appear until the Apple logo appears. Let go of the buttons and let the device restart. And then reboot your computer.
    See if that fixes your problem.

  • Search result to get data from bing search and display it in sharepoint page.

    I have configured result source which gets data from bing site,i have given following url as source url
    http://www.bing.com/search?q={?searchterms}&format=rss&Market=en-Us
    but it returns only 8 results from RSS. i want to get all results of search and display it in my SharePoint search results page. 
    any pointers will be helpful. 

    Hi,
    According to your post, my understanding is that you wanted to search result to get data from bing search and displayed it in sharepoint page.
    To display more items, you can modify the item number when you add
    New Query Rule.
    To get all results, I recommend to use the “Show More”
    link in the result page.
    You can enter the URL when you add New Query Rule:
    "More" link goes to the following URL: http://www.bing.com/search?q={searchterms}
    Here is a great blog for your reference:
    http://sharepoint-community.net/profiles/blogs/integrate-bing-with-sharepoint-online-2013-search
    Best Regards,
    Linda Li
    Linda Li
    TechNet Community Support

Maybe you are looking for

  • Slow rendering from DVCPro-HD to MPEG2-DVD?

    I have a home built PC with a quadcore 9450 chip, 8GB ram, Vista-64 Business, Mercury rendering (GTX460) - so it's not a particularly slow machine. My current project is 2 hours, 45 minutes long, shot on DVC-Pro HD 720-30P.  It is one continuous take

  • Using Accelerometer to detect a panning motion

    i'm wondering if it is even possible and is so, how would i go about detecting a user panning the iphone from side to side (as in when one is framing a picture). i really just want to know when the phone is moving and direction. i don't really need a

  • Is there any java File Poller class example??

    Dear Sir: My project requires to write a java class to perform something like File Poller function, ie. this File Poller Class will monitor some remote or local location/directory, then when some files were dropped in this location, File Poller Class

  • Product customization in CRM 7.0

    Hi experts. How can be able to do product customization in crm 7.0, if crm is not a standalone system how come we will proceed further. PLease share the infromation Thanks in advance Prajith P

  • App not on computer but is in CC manager. Where is it?

    I have downloaded Acobat XI via the CC manager, but it's not appearing on my PC, even though the App Manager says it's there and it's up to date. It's not appearing in my programs list and it's not appearing as an option to use to read PDFs. I need t