Different general polynomial fit results
Hello,
I've encountered a strange problem using the general polynomial fit: It seems that the outcome of this vi is computer dependent...
I'm using labview 8.2.1, and tried to use the vi to get a polynomial fit (with an order between 12 and 20) on about 450 datapoints, which seemed to work fine... until I shared my vi with another person, where different results for the polynomial coefficients were obtained with the same datapoints (and the same parameter settings). I noticed that the differences get bigger when the requested order increases.
has anybody encountered a similar problem?
greetings,
Hans
Attachments:
get_polyline.vi 37 KB
Well, taking a 20th order polynomial does not make a lot of sense anyway. What are you trying to achieve? There are probably better ways to do whatever you want to do here. You are dealing with extreme intermediary values (e.g. 1500^20=3.32e+63) so a slight reordering in operation could change the outcome.
Can you explain the differences between the computers? Is the other a different OS (e.g. mac vs windows)? Just curious.
LabVIEW Champion . Do more with less code and in less time .
Similar Messages
-
I need to fit a polynomial function and extract the coefficients a0, a1, etc, of my data. But in the General Polynomial Fit i have to especified the order, is there any way to find automatically the polynomial order and then extract the coefficients? Thank you.
Thinking about this question again, I`m not sure I`ve answered the correct question at all.
My original method (Scanning different fit orders) will give aou an N-order Polynomial which fits the signal well, but the assumption that your signal is then also an N-order Polynomial is generally false. If you are simply looking for a polynomial which well describes your signal, this is OK.
If you are dealing with simple clean signals then you MIGHT be able to make assumptions on the signal type based on various fit coefficients, but if you`re trying to understand fundamentals of a real-world complex signal based on fit-algorithm errors, I would be, in addition to the other respondants, very cautious. I`m not a very good mathmatecian (I love that the fit algorith
ms simply ), so I can`t begin to give a hint as to do this kind of analysis.
Shane.
Using LV 6.1 and 8.2.1 on W2k (SP4) and WXP (SP2) -
How to use General Polynomial Fit
Hey,
Very new to LabVIEW (mostly use Matlab) and I'm trying to use the General Polynomial Fit VI and I have found the built-in help for LabVIEW very lacking and the examples not much better. The help says that, among other things, the inputs are the x and y data points. I have my data in 1D arrays of double, but this is apparently the wrong format for the VI it states that the VI needs it in double. This would imply that it only takes one data point at at time? Do you have to build it up one point at a time in a loop?
Thanks in advance for any help,
dnormanOops, nevermind. Accidentally selected the point by point variation...
-
"Residue" in General Polynomial Fit Function
Do any of you statistics wonks understand how LabVIEW calculates the "residue" output in the "General Polynomial Fit" function? How does it relate to the R^2 value on an Excel polynomial trendline.
I've been trying to figure this out for hours, but the LV help files don't seem to have the info I am looking for, and I cannot find a good explanation on line.
Thanks,
FB
Solved!
Go to Solution.I figured it out. I was looking at the TOTAL error of all elements, rather than the average error.
-
Using General Polynomial Fit VI with waveform graph
Hello gurus ,
I would like to ask how to use General Polynomial Fit VI with waveform graph not GraphXY .
Waveform graph is giving me an array of values not X , Y i think , what should i do ?
Thanks in advance
Solved!
Go to Solution.Hi Omar,
i changed the shipped Labview Example to use the General Polynomial Fit VI with a waveform graph.
But why don't you want to use a X-Y-Graph?
Regards
DianaS
Attachments:
test.vi 37 KB -
Chebychev Polynomial fitting results show multi lines
I am using "nonliear curve fit.vi" with defined Chebychev Polynomial function to fit XY data. Strangely, if I enlarge the upturn part, I clearly see the fitting results show multi-lines (2-4) . Please the the attached snapshot.
weitong
LV2013
Attachments:
chebychev Ploynomial fit.PNG 48 KB
chebychev Ploynomial fit-whole.PNG 19 KBThanks.
I found the reason: the data X values are not mononicaly, i. e. there are local oscillations at some region.
After sorting the raw data, the fitting results show single line.
Is the sorting of X values necessary before Chebychev Polynomial fitting? -
I want to do a 2-dimensional polynomial fit. How can I do this is LabVIEW or LabVIEW/IMAQ ?
MarcI am not sure what kind of polynomial fit you want to do. LabVIEW offers a generalized least squares VIs for calculating the surface that minimizes the distance to all the data points. Can you explain what you want to do better?
Jeremy -
Different ways to return results using a stored proc to calling application
Hi, Can someone please suggest me different ways of returning results( set of rows and columns) from a stored procedure to calling application.
Currently I am using sys_refcursor to return results to front end. Stored proc is executed fast, but cursor access and retrieval of results has some overhead.
So can you suggest the ways which will be faster than this approach.
Thanks.Currently the procedure executes quickly but the results from the ref cursor are returned slowly, this is because the query is slow, for whatever reason.
Collecting in all the rows in the stored procedure first before returning them will
a) Make the stored procedure slower taking the same amount of time to execute as current query takes to complete.
b) Use more memory.
c) Put more stress on the network as all rows will be transferred at once instead of using the arraysize/fetchsize to to fetch the rows in smaller packets. -
Polynomial fitting for scatter plot
Hi all,
I was wondering if there is any way to generate a polynomial fit to a scatter plot just like in excel. The data I am trying to fit has several y values for each x value.
Thanks
Krish
Solved!
Go to Solution.Well, my "solution" above is a bit misleading, because the polynomial fit of course does NOT depend on the x ordering. If the x-values are scranbled as in your case, a maybe better solution would be to simply create a linear x-ramp over the data range and use polynomial evaluation to calculate a smooth best fit line. This has also the advantage tha a smooth curve is generated even if the data points are sometimes far apart.
Here is one possible modification to show the technique.
LabVIEW Champion . Do more with less code and in less time .
Attachments:
Scatterplot_fitting_MODCA2.vi 13 KB -
I can't use the prebuilt VIs because the libraries take up too much memory on my FP-2000s. Anyone built up a polynomial fit VI that doesn't include the LV libraries or dlls?
Thanks,
Bill
Solved!
Go to Solution.Hey Bill,
That puts you to about 21-22Mb MAX. Doesn't it fit?
It seems like you may want to look into a controller with larger memory, such as the 2010/2015 or the newer compact FieldPoint controllers.
Aashish M
Applications Engineer
National Instruments
http://www.ni.com/support/ -
BEx report -two different calculations for a result for one key figure how?
All,
Maybe someone could help me with the following, we have a requirement to setup for one key figure two calculations for result rows. One result (average) for one level, and on a higher level -grand total have a (sum), as for our business it makes sense to do it this way. We have setup average for this KF, we get correct results (see below values 7,5 & 6,5) however for the grand total (across multiple products) so for one level up we need to have a different calculation. How could we achieve this?
Here is an example:
location product inventory
AAAA 11111 5
AAAA 11111 5
AAAA 11111 10
AAAA 11111 10
AAAA Result 7,5 ---> average
AAAA 22222 5
AAAA 22222 6
AAAA 22222 7
AAAA 22222 8
AAAA Result 6,5 -
> average
AAAA Result (across products) 14 ---> here I want to have a sum of averagesThis could be achieve only IF you upload a hierarchy for product inventory with different levels, wherein each level show subtotals and finally grand total will be shown at the end of the results.
-
Deployment Tool, Different Config Files, Same Results
I should mention that I'm generating App-V 5 packages for Office 2013. Maybe this question belongs in the App-V forums.
I can't seem to create a configuration file for the Office Deployment Tool that does what I want. This configuration:
<Configuration>
<Add SourcePath="D:\Something\Something\Source\Full Suite" OfficeClientEdition="32">
<Product ID="ProPlusVolume">
<Language ID="en-us" />
</Product>
<Product ID="VisioProVolume">
<Language ID="en-us" />
</Product>
<Product ID="ProjectProVolume">
<Language ID="en-us" />
</Product>
</Add>
</Configuration>
generates an App-V package with the "basic" Office apps (Word, Excel, etc.), along with Visio and Project. That part is fine.
If I remove the Product elements for Project and Visio, I expect that a "basic" Office package will be created. However, Visio and Project are still in the package, and they are indeed usable. We have limited licenses for Project and Visio, so
I would like them not to be deployed to every machine.
I have tried giving the two configuration files their own source folders, that is, running the download command once for each configuration file and telling it to download to two different folders... same results.
This is similar to John Marcum's follow-up question at
https://social.technet.microsoft.com/Forums/office/en-US/c9462446-7744-4e3e-8c25-dbcd185a17e4/creating-lync-and-onenote-appv-packages?forum=officesetupdeployKazzan's reply technically does work, and it is a viable option. However, that reply led me to wonder what the Office Deployment Tool (ODT) is doing to a machine that makes generating different packages difficult or impossible.
I found that the ODT leaves files behind in the current user's Temp directory, after the package generation is finished. At least one of these folders (named Microsoft Office 15) contains the file system contents of the App-V package. So, I decided
to clear the Temp directory in between runs of the Office Deployment Tool. Simply clearing this directory was not enough to solve the problem, but I'm still doing it as part of the build process.
Running Process Monitor showed me activity in HKCU\Software\Microsoft\Office\15.0\ClickToRun. Deleting this entire key does not appear to be necessary, and I'm not sure what that would do if you actually used Office Click-To-Run on the same machine on which
you're running ODT. So, I deleted just these keys:
HKCU\Software\Microsoft\Office\15.0\ClickToRun\Configuration
HKCU\Software\Microsoft\Office\15.0\ClickToRun\ProductReleaseIDs
HKCU\Software\Microsoft\Office\15.0\ClickToRun\Scenario\APPVPACKAGE
Deleting those keys, along with the Temp directory cleanup, is sufficient to let me build multiple Office 2013 App-V 5 packages on the same computer. -
Dear Users of LabWindows,
I am using "StdDev" from "analysis.h" in a program.
I am using LabWindows 2012 and Win 7 64 Bit.
The program gives me a (right) calculation result on my development PC by using "StdDev".
On a PC with only the runtime I receive a different (wrong) calculation result.
What could be the problem?
I watched in the forum about half an hour to find some similar error but I only found hints for the two solutions below:
Do I need to include to the project the "analysis.lib"-file?
In my distribution in the "Edit Installer"-window in the TAB "Drivers & Components" I have "only" selected the sub-option "Standard Run-Time" in the main option "NI LabWindows/CVI Shared Run-Time Engine". Do I need to add the sub-option "Analysis Support" too?
Actually I haven't tested these two possible solutions. I asking myself and this forum: Could this be the solution?
I am asking myself because in my actual project I get no error:
Neither on clicking "Check Module Dependencies" in TAB "Drivers & Components", Nor in any usage of the program on my deleoper PC or the user PC with only the "Standard Run-Time".
I witness no compile error or warning (my setting is "Aggressive" an everythin is checked) no non-fatal no fatal run-time error no error at all.
Could the above described error also be caused by different "Country Settings" of the Windows-System itself? This means "," instead of ".".
Best greetings to all who may help me.Calling an advanced analysis function without providing its library should throw an error;
do you check for the return value, i.e., status = StdDev ()? In your case status should be something like -5093 (The analysis library was not found).
You do not need to include the analysis.lib file in your project but in your distribution, i.e., you need to check 'Analysis Support'. If you click on Analysis Support (the text, not the checkmark) on the right side of the panel there is a little explanation saying 'Include this component when your application calls Analysis Library functions'. -
Different sequence of search results in different environments with same set of documents
I am using Sharepoint 2013 Foundation version.
I have set up 2 environments (say environment A and environment B) with the same Window baseline and Sharepoint server farm setup. The similar set of documents have been uploaded to both environments. With input of exactly the same search string at the search
field and enter button pressed, the sequences of entries shown on search result page are different in these 2 environments.
In particular, there is a document 'Monthly Newsletter.pdf' uploaded in both environments. When I type 'Monthly Newsletter' in search field and press enter, this document appears as the first entry in the search result in environment A, but this same document
appears as the 8th entry in the search result in environment B.
May I know the reason? Thanks a lot for advice!There are a lot of factors that go into computing the "relevance" of any one document. One factor is "closeness". So one question would be how identical are the two environments? Same number of site collections? Are the
documents at the same depth? (sites -> subsites -> libraries -> folders) Are the libraries of the same type, using the same content types and the same metadata> In both cases are you searching from
the same site and are the documents at the same depth?
Ranking is also impacted by past searches. The more people who have clicked through to the document, the higher it will be ranked in the future.
If the two environments are identical, and are only being used for testing, Reset the Indexes and do a new Full Crawl and then test.
Mike Smith TechTrainingNotes.blogspot.com
Books:
SharePoint 2007 2010 Customization for the Site Owner,
SharePoint 2010 Security for the Site Owner -
Same query takes different time to fetch result from Database
Hi all,
I am having a scenario in which a query is taking different time keeping other environmental variables constant.
When that query runs for 1 user it takes just 2 minutes to fetch result and the DB connection becomes inactive after fetching the result.
But if I run the same query after some time in similar environment it takes 25 minutes. sometimes 40 minutes to execute and give the result to the app server from the same database.
I am not able to understand this behavior from DB. Can anybody try to explain this behavior?
The details of the DB are,
Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
PL/SQL Release 11.2.0.1.0 - Production
CORE 11.2.0.1.0 Production
TNS for 32-bit Windows: Version 11.2.0.1.0 - Production
NLSRTL Version 11.2.0.1.0 - Production
OS Details:
Windows 2008 server Enterprise Edition.
I tried analyzing that query in oracle, it recommended there are lots of hard parsing in that query.
Regards,user10915512 wrote:
Hi all,
I am having a scenario in which a query is taking different time keeping other environmental variables constant.
When that query runs for 1 user it takes just 2 minutes to fetch result and the DB connection becomes inactive after fetching the result.
But if I run the same query after some time in similar environmentBut not exactly the same environment. So what is different that it is only "similar"?
it takes 25 minutes. sometimes 40 minutes to execute and give the result to the app server from the same database.
I am not able to understand this behavior from DB. Can anybody try to explain this behavior?Run a statspack on the 'well behaved' query and on the 'not well behaved' query. Compare and contrast the results.
>
The details of the DB are,
Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
PL/SQL Release 11.2.0.1.0 - Production
CORE 11.2.0.1.0 Production
TNS for 32-bit Windows: Version 11.2.0.1.0 - Production
NLSRTL Version 11.2.0.1.0 - Production
OS Details:
Windows 2008 server Enterprise Edition. To paraphrase Forest Gump, "My momma always said Windows was like a box of chocolates ...."
>
>
I tried analyzing that query in oracle, it recommended there are lots of hard parsing in that query.
Regards,
Maybe you are looking for
-
Why can't I transfer music files from i-Tunes to my 30GB ipod?
I have just updated the software on my ipod, and now there seems to be a major problem. When I drag a song from the i-Tunes library to the ipod folder it has a 30% success rate - the other 70% gets the message "attempting to copy to the disk 'name' f
-
Using dbms_metadata to get ddl for creating directories
Hi, I am working on creating a test database, which is a copy of production for 11g upgrade testing. I want to get all the ddls from my production databse to create all the directories in the new test database. I have been trying to use dbms_metadata
-
Snow Leopard Mail - Bouncing Icon/Play Sound Rules Cancel Each Other Out
I recently saw a movie which featured many closeups of a MacBook Pro being used; every time the actor got an e-mail message, the Mail icon bounced in the Dock AND played the New Message Sound. In the current version of Snow Leopard Mail, you can crea
-
Multiple endpoints for HTTP adapter (OracleAS 10g - 10.1.2)
The HTTP adapter documentation states the HTTP adapter supports sending outgoing messages for Interconnect to multiple HTTP endpoints. This enables sending messages to various remote web servers. The HTTP user guide states: "An endpoint is associated
-
Background images are not loading in Firefox nor IE, running Win 7 Home Premium
Win 7 laptop does not load background type images in either Firefox or IE. XP laptop shows background images while using page info/media tab.