Fitting a Gaussian curve onto a set of data

I'm looking to plot a best fit Gaussian curve unto a set of data and was wondering if this is possible with just the labview 7 base development software. Any help would be greatly appreciated

I assume you are trying to find a gaussian ditribution function to fit to the data. All you need is to find the average and the sample standard deviation of your data and then build the Gaussian function. You can plot that, you can also plot a histogram of your data to compare to the Gaussian plot.
With little programming code, you should be able to do that.

Similar Messages

  • Gaussian Peak Fit and Nonlinear Curve Fit on small data differ from Origin Peak fit

    Hi all,
    I am developing a program in which I have to fit Gaussian curve on only 4 or 5 data points. When I am using Gaussian Peak Fit or Nonlinear Curve fit, it linearly connects all the points while other fitting software like Origin is fitting Gaussian curve on the same set of data I have attached two images One is from Labview with Gaussian Peak Fit and NonLinear Fit and other is from Origin.
    Data is
    X                       Y
    799.09857        257
    912.25256        641
    1026.00366     1516
    1137.92871     1118
    1253.43713     329
    Labview user
    Solved!
    Go to Solution.
    Attachments:
    Origin_Fit.PNG ‏21 KB
    Labview_fit.PNG ‏15 KB

    That looks like a plot of the input data.
    When I run it with your data I get a Gaussian curve which looks much like your Origin plot.
    The Plot 2 curve is from 128 points equally spaced along X and Y calculated from the Gaussian formula in the LV help using the output parameters from the fit.  Plot 1 is the Best Gaussian Fit output from the fit VI.  It only has five points.
    I used default values for everything except X and Y.
    Lynn

  • Creating a bell-shapped (Gaussian) curve with the Pen Tool

    Hello everyone,
    I'm trying to create a bell-shaped (Gaussian) curve in Photoshop CS3, using the Pen Tool, however apparently I am not good enough with it... I can create a curve that resembles a simple parabola - like this one http://4.bp.blogspot.com/_BhBX8ycVeL4/SIHhJYmDCgI/AAAAAAAAA-g/2Dc_Tf1Kz5c/s400/400px-Para bola.svg.png only upside-down; however I can't figure out how to further go from here in order to add the extra inflexions on the sides that make the parabola into a Gaussian curve, that would look something like this: http://naturalcureinsomnia.com/img/Bell-Curve.gif
    Can anyone help? Thanks in advance!

    Art,
    Correct me if I'm wrong---I believe you want a schematic Gaussian curve rather than a mathematically precise one.
    If so, set up two horizontal guide lines, one running through the desired apex and the other through the curve's baseline. Add three vertical guides, one through the apex and the other two equally spaced on the left and right sides of the guide through the apex.
    Let point A be at the intersection of the left vertical with the baseline, point B be the apex, and point C be the intersection of the right vertical with the baseline.
    With the pen tool at point A, drag horizontally to the right a fraction of the distance to the central guide. Release the mouse, move the pen tool to point B and drag horizontally to the right about the same distance or until the left half of the curve looks Gaussian. Release the mouse, place the pen tool at point C and drag horizontally rightward until the right half of the Gaussian curve matches the left.
    To close the curve, release the mouse and click at a point on the baseline well beyond point C, connect from below with a path of any shape to a point on the baseline well to the left of point A, and then close to point A. Stroke the path, delete the path, and erase all but the Gaussian part.
    Experiment with the ABC positions and the drag lengths until you get a decent curve. Should you want a precise curve it would be better to use one of the freeware curve programs out there. But if you want a bit of precision with the pen tool, that's possible by calculating one or two intermediate points between A and B and symmetrically between B and C and then dragging the pen so that curve comes reasonably close to passing through them.

  • Lorentz fit of a curve with Lev-Mar

    Hello everybody! I am trying to set of data to a Lorentz curve to calculate a Q value (resonance.) I found a program on a thread from this forum that appears to work with the sample data set from the thread. However, when I try to run the program using my data set with known fitted coefficients as the initial guesses, we get an error in the Lev-Mar sub-VI -- something like “the input matrix is singular”. There’s a screenshot of my data in in the attached zip folder, as well as the text file containing my data.
    My data curves down (reaching a minimum) instead of up, as in the sample data set, but it seems like that should be accounted for by the different initial guesses. I am thinking that something else is going on; hopefully it is something simple that I am just missing. Any help y'all can provide would be greatly appreciated!
    Thank you!
    Attachments:
    Lorentz Fit.zip ‏1992 KB

    Hello Lynn,
    Yes, there are quite a few potential peaks in that data set. The peak you identified was the one that we are trying to fit (The peak should be trimmed by the cursors.) We used origin to fit that same peak in order to get the initial guesses for the coefficients in the screenshot. When it runs, we get the error message: "Error -20041 occured at NI_Gmath.lvlib: Nonlinear Curve Fit LM.vi:2 Possible reason(s): Analysis: The system of equations cannot be solved because the input matrix is singular." 
    Thanks!
    -Garrison

  • How to add a gaussian curve on a histogram chart.

    I want to add a gaussian curve on the histogram chart like the attached picture. I plot the histogram already with my data, but I don't know how to add the gaussian curve.
    I appreciate your help very much.
    Solved!
    Go to Solution.
    Attachments:
    histogram_dis.JPG ‏37 KB

    If you have the Statistical Process Control (SPC) toolkit or Datalogging and Supervisory Control toolkit (DSC), LabVIEW has many built-in histogram functions.
    look for "Plot Histogram and Normal PDF"
    Attachments:
    histo.JPG ‏76 KB

  • Fitting larger video files onto DVDs?

    I'm working on a project, videos + stills but mostly videos from a week's holiday (in Wales -- beautiful country, by the way, great people, great food and beer -- highly recommended!  And of course great scenery with the little mountain railways, including one to the top of Mount Snowdon, but I digress, sorry).
    The finished project will be about 1½ hrs long, but so far I have a completed video (.m2t) for each of 4 days, with the following sizes:- 1.26  4.50  4.66  2.98  = 13.4GB
    Originally I'd been wildly optimistic and hoped to fit the whole week onto 1 DVD, clearly impossible without destroying the quality.   I do have a Bluray player and my pc can also record Bluray, but I don't want to use this as the people I'd like to send copies to don't have Bluray players.
    Will I then have to accept that I'll have to make separate DVDs for the larger movies, ie the 4+ GB ones?   It's no big deal, and in fact will save me having to learn and practise making menus (lazy! only kidding).
    I've seen on the web software for 'shrinking' videos to size to fit DVDs but they probably ruin the quality?
    Thanks for help with this.
    Brian

    Brian
    Good morning.
    Are you saying that your burner does not burn Blu-ray or are you saying that Premiere Elements burn to is not recognizing your Blu-ray DVD CD burner? I think you said burner is not spec'd for Blu-ray, but just wanted to make sure.
    Premiere Elements does not have a burn to folder for Blu-ray, but what you might consider:
    a. Burn to Folder for Publish+Share/Disc/AVCHD with Presets = H.264 1920 x 1080i Dolby DVD
    b. Take the BDMV Folder from that and put it on a Blu-ray disc with a program such as ImgBurn.
    We could also think about the Phantom burner Premiere Elements combo approach to getting a disc image. But we will save that for later. It does work with Premiere Elements 11 Windows 7 64 bit, but there is a bit of a twist to it.
    Best if you have BD-RE so that you can reuse the disc if necessary.
    I have one Blu-ray DVD CD burner and its internal type. So, I do not have any first hand information on preferred external ones. When I have looked, the ones I likes were out of my price range (most are). What I once thought about doing was buying an internal one (one of the bargins/sales) and an enclosure and making my own "external" Blu-ray DVD CD burner. That is essentially an easy assembly and nothing high tech.
    Whatever you buy, make sure you can return it if Premiere Elements does not recognize it or has other problems with it.
    ATR

  • Cut off some data from a set of data

    I have a set of data our of from power spectral density measurement.
    I want to curve fitting with the data.
    But I want to cut off below a certain frequency.  For instance, the PSD
    data
    contains {(1,10),(2,3),(3,4),(4,3),...} and I want to fit from 3 Hz
    {(3,4),(4,3)...}.
    I tried high pass filter but it does not change.  I tried several ways such
    as
    get time stamp and find the index for the element and remove the array
    using
    'Array'tools.  It cuts off the data sets that I wanted to remove but it
    does
    not remove the frequency values.  So it works like {(1,4),(2,3)....}
    instead of
    {(3,4),(2,3)..}.  Please let me know how I can make this work.
    Thanks.
    Attachments:
    new-PSD-factor-v3.vi ‏522 KB

    Hey Arrow,
    I think I understand your question better now. You'll want to use the "delete from array.vi". It can be found by going to all functions>>Array. You'll need to input the array to be edited, which index to begin deleting from and how many elements to delete. From your application it sounds like you'll want to start from element zero and delete the number of elements that corresponds to 0 through 4 Hz.
    In addition, you'll need to create an array that represents the frequencies you want to plot (4 1000 Hz or your upper limit). There'll need to be one frequency on your x axis for each element in your PSD array. Then bundle the two arrays together and plot them on an XY plot. You can use the "bundle" vi to accomplish this. You can find examples using clusters from help>>find examples. Then navigate to Fundamentals>>Arrays and Clusters.
    Hope this helps out.
    Chris Cilino
    National Instruments
    LabVIEW Product Marketing Manager
    Certified LabVIEW Architect

  • How to plot a log graph using grapher with a given set of data

    hi there,
    im just wondering is it possible to plot a log graph in the grapher software with a given set of data, and also give an error bar and a best-fit line for it?
    so here is the set of data,
    Concentration of BCh (M)
    Mean % Specific Binding (%)
    Standard Deviation
    3 ×10⁻⁹
    71.52
    9.52
    1 ×10⁻⁸
    57.30
    8.56
    3 ×10⁻⁸
    39.15
    9.40
    1 ×10⁻⁷
    24.13
    10.15
    3 ×10⁻⁷
    14.77
    3.31
    1 ×10⁻⁶
    7.22
    2.02
    hope someone could help

    Try these:
    http://y.barois.free.fr/grapher/Bienvenue.html
    http://homepage.mac.com/tlindywizdumb/math/Grapher_index.htm
    http://homepage.mac.com/tlindywizdumb/math/Grapher/Grapher_HowTo.pdf

  • How do I set a data limit on my Verizon Jetpack MiFi 5510L?

    I bought a Jetpack with 16 GB a month. I don't like the idea of Overage charges. even though I have been using my data safely. I've currently used 12 GB from a 12/19 - 1/19 cycle with 5 wifi devices. But soon, I will not be here to monitor the data usage for my family members and I'm afraid it will spike when I'm gone. So I want to set my jetpack to automatically stop when it hits 16 gb. is there some option to prevent the data from going past the limit?

        Setting up data limits are easier than ever KeatonTS! May I ask are you subscribed to Family Base? If so then you can add and change the data allowance on you jetpack as you see fit. Here's a link to help you out with this amazing service.
    http://www.verizonwireless.com/support/verizon-familybase-and-usage-controls/
    Thank you…
    ArnettH_VZW
    Follow us on Twitter @VZWSupport

  • In new iPad 4g, when sim card is not inserted, I can not find the enable 4g tap in the setting-cellular data tap, can some one please tell me if this is normal and if so, then when it appears, thanks

    In new iPad 4g, when sim card is not inserted, I can not find the enable 4g tap in the setting-cellular data tap, can some one please tell me if this is normal and if so, then when it appears, thanks

    If the SIM is out of your phone, find my phone needs a data connection, so could use wifi - IF in range of a wifi and one that it can join (ie. a known network or one that is wholly open so no login required).  Your phone could also simple be turned off, so not findable, or it may have been restored (plugged into iTunes and restored as new) again, making it permanently unfindable.  Honestly, for someone stealing an iPhone, this is likely the first thing they do - restore as new and it is theirs forever.
    Find my iPhone is tied to the users iCloud account - the find function is part of the iCloud account's services and it communicates with the iCloud servers over a data connection - either wifi or 3G.
    Have you set up your iCloud account on your replacement phone, and is it working properly on that phone?

  • Trying to programmatically set the data-source for a Crystal reports report.

    I've got the following existing procedure that I need to add to in order to programmatically set the data-source (server, database, username, and password) for a Crystal reports report.
     I added the connectionInfo parts, but can’t figure out how to attach this to the existing
    this._report object.
    This is currently getting the connection data from the report file, but I now need to populate this connection data from a 'config.xml' text file.
    Am I trying to do this all wrong?
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using CrystalDecisions.CrystalReports.Engine;
    using WGS.Reports.Reports;
    using CrystalDecisions.Shared;
    using WGS.Reports.Forms;
    namespace WGS.Reports
    public class ReportService
    ReportClass _report;
    ParameterFields paramFields;
    ConnectionInfo connectionInfo; // <- I added this
    public ReportService()
    public void DisplayReport(string reportName, int allocationNo)
    if (reportName.ToLower() == "allocationexceptions")
    this._report = new AllocationExceptions();
    PrepareConnection(); // <- I added this
    PrepareAllocationExceptionReport(allocationNo);
    this.DisplayReport();
    private void PrepareConnection() // <- I added this
    //test - these will come from the config.xml file
    this.connectionInfo = new ConnectionInfo();
    this.connectionInfo.ServerName = "testserv\\test";
    this.connectionInfo.DatabaseName = "testdb";
    this.connectionInfo.UserID = "testuser";
    this.connectionInfo.Password = "test";
    this.connectionInfo.Type = ConnectionInfoType.SQL;
    private void PrepareAllocationExceptionReport(int allocationNo)
    this.paramFields = new ParameterFields();
    this.paramFields.Clear();
    ParameterField paramField = new ParameterField { ParameterFieldName = "@AllocationNo" };
    ParameterDiscreteValue discreteVal = new ParameterDiscreteValue { Value = allocationNo };
    paramField.CurrentValues.Add(discreteVal);
    paramFields.Add(paramField);
    private void DisplayReport()
    frmReportViewer showReport = new frmReportViewer();
    showReport.ReportViewer.ReportSource = this._report;
    showReport.ReportViewer.ParameterFieldInfo = paramFields;
    showReport.ShowDialog();
    showReport.Dispose();
    Any help would be much appreciated.

    Hi Garry,
    Please post SAP Crystal Reports questions in their own forums here:
    SAP Crystal Reports, version for Visual Studio
    We don't provide support for this control now. Thanks for your understanding.
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • HT1660 How can I maintain two separate itunes accounts on one single device without erasing either set of data?

    How can I maintain two separate itunes accounts on one single device (iPhone 4) without erasing either set of data when syncing with itunes?

    Hi,
    Depends on what you trying to setup but for purchases, you can roll down at the very end of the iTunes/AppStore pages to logout of your current account and then login into a different one.  Then your purchase will be billded to this new account.  Everything will sync as you used to but in order to use the purchased content in iTunes or other devices, you will need to authorize them (you can have up to 5 devices authorized for an account).

  • Set variable date in a procedure with current month and previous month

    Hi guys, I need to set two date range in one procedure. The date should be
    @datefrom the third day of the current month
    @dateto the seventh day of the current month
    @datefrom-1 the third day of the previous month
    @dateto-1 the seventh day of the previous month
    format like @datefrom '2014-03-03' @dateto '2014-03-07'
    @datefrom '2014-02-03' @dateto '2014-02-07'
    The problem for me it's going to be the jump between the years...2014 to 2015...any advice?
    Thanks

    DECLARE @FirstDayOfCurrentMonth DATE
    SELECT @FirstDayOfCurrentMonth = DATEADD(MONTH, DATEDIFF(MONTH, '01/01/1900', Current_timeStamp), '01/01/1900')
    SELECT
    DATEADD(DAY, 2, @FirstDayOfCurrentMonth) As ThirdDayOfCurrentMonth
    ,DATEADD(DAY, 6, @FirstDayOfCurrentMonth) As SeventhDayOfCurrentMonth
    ,DATEADD(DAY, 2, DATEADD(MONTH, -1, @FirstDayOfCurrentMonth)) As ThirdDayOfPreviousMonth
    ,DATEADD(DAY, 6, DATEADD(MONTH, -1, @FirstDayOfCurrentMonth)) As SeventhDayOfPreviousMonth
    OUTPUT
    ThirdDayOfCurrentMonth SeventhDayOfCurrentMonth ThirdDayOfPreviousMonth SeventhDayOfPreviousMonth
    2014-12-03 2014-12-07 2014-11-03 2014-11-07
    Best Wishes, Arbi; Please vote if you find this posting was helpful or Mark it as answered.

  • How can I set the data binding between Web Dynpro & Database table

    Dear friend,
    I am a beginner of Web Dynpro. I want to develop my simple project like these:
    1. Create my own database table via Dictionary Project such as TAB_USER and have 3 fields: USER_ID, USER_NAME, USER_POSITION and I have already deployed & archived it.
    2. Create my own Web Dynpro Project, and create the input fields as User ID, User name, User position and icon 'Save' on the selection screen and I have deployed it already.
    For the process, I want to input data at the screen and save the data in the table, please give me the guide line like these:
    1. How can I set the data binding between Web Dynpro and Database table ?
    2.  Are there any nescessary steps that I will concern for this case?
    Sorry if my question is simple, I had try  to find solution myself, but it not found
    Thanks in advances,
    SeMs

    Hi,
    You can write your own connection class for establishing the connection with DB.
    Ex:
    public class  ConnectionClass {
    static Connection con = null;
    public static Connection getConnection() {
    try{
    Context ctx = new InitialContext();
    DataSource ds = (DataSource) ctx.lookup("jdbc/TSPAGE");
    con = ds.getConnection();
    return con;
    }catch(Exception e){
    return null;
    You can place the above class file in src folder and you can use this class in webdynpro.
    You can have another UserInfo class for reading and writing the data into the DB .
    Regards, Anilkumar
    PS : Refer
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/webas/java/simple java bean generator for database.pdf
    Message was edited by: Anilkumar Vippagunta

  • Error when trying to set a date type edit field

    Hi all
    I have an edit text field in a form which is bounded to a date type
    database field using dbDataSource.
    When i try to set the edit text field value with Today's date by code.
    I recieve an error message that the value which
    i'm trying to set is not legal. the  error number is [131-183].
    I use the following code to set the edit field:
    If oEditText.Value.Trim = String.Empty Then
                Dim strDate As String
                Dim sboBob As SAPbobsCOM.SBObob =
                 oCompany.GetBusinessObjec(SAPbobsCOM.BoObjectTypes.BoBridge)
                 rs = sboBob.Format_DateToString(Microsoft.VisualBasic.Today)
               strDate = rs.Fields.Item(0).Value.ToString().Trim()
    Try 
           oEditText.Value = strDate
    Catch ex As Exception
        SBO_Application.MessageBox("error setting
    current date: " & ex.Message)
    End Try
    End If
    My question is how can i set the edit field with a valid value?

    Hi!
    When writing to EditText.Value you must always use the B1 "DB-Format" as String.
    The following examples are assuming (it's a must!) that the EditText-Fields are bound to a corrosponding DataSource (Type Date, Price etc...)
    MyDateEditTxt.Value="20080207"
    MyPriceEditTxt.Value="1341.79"
    The best of it: It's Windows and SBO-GUI-Language independent.
    EditText.String must always be written with the format of the actual Language of the SBO-GUI, which can be changed by the user....
    You may also have a look at my statements regarding these problems near the end of this thread:
    [How to pass date value to an UDF;
    Cheers,
    Roland

Maybe you are looking for

  • How do I have more than one web page on at a time?

    I can only watch or use one web page at a time. I f I try to get on something else it will knock me out of what I was doing on the other page.

  • Adding 1099 Tax Codes after payment of the invoices ?

    Hi ! We have a client where the 1099 Codes were not added in vendor master, and obviously in invoices , subsequently the payments have been posted to the vendors a few months back. Now it is realized that the 1099 info is missing from the reports and

  • Suddenly can't drag songs to a different order in playlists.  Help?

    I used to click and drag songs in my Itunes playlists to burn CD's in a specific order.  All of a sudden I cannot move the songs.  Click and drag isn't working.  I have had Itunes for about 7-8 years and this is the first problem I've had.  Any help?

  • SAP SCM 5.0 Upgrade

    Starting a forum thread for those of us who are upgrading to SCM 5.0    Please comment on the scope and/or challenges of your project.    Please post any advice.   Our upgrade project begins in January.   We will migrate from SCM 4.0 SP 18 to 5.0.   

  • Sharing with my family

    I have 5 family members all with their own apple computers and all with their own itunes accounts. I would like to know how I can easily share music my wife and I have already bought under our Itunes accounts.  Is there a better way to share for the