Questions on the use of Mathematica to construct models for approximating empirical data.

learn more… | top users | synonyms (3)

0
votes
0answers
48 views

Incorporating sophisticated constraints on the approximating function into NMinimize

Following the approach as given in the answer of Belisarius here I just wonder how one could incorporate some more sophisticated requirements on the approximating function. Suppose the approximating ...
7
votes
2answers
403 views

Maxwell fit in 2 dimensions

The histogram below shows the 2D-velocities v of a micrometer sized particle in a plasma measured from image to image (60 Hz) over 33,33 sec. I would like to fit ...
3
votes
1answer
141 views

Estimated Variance in LinearModelFit

Suppose that lmModel is a linear model which is fit using LinearModelFit. How come ...
4
votes
2answers
187 views

FindFit and NMinimize to fit a parametric model (minimize the distance of two curves)

I am trying to find a fit to the cumulative distribution of a set of points using FindFit or NMinimize. In particular, I would like to find the parameters of the cdf of the Beta Distribution that ...
3
votes
3answers
185 views

FindFit with a sophisticated function (integral)

I am trying to find a fit to the distribution function (empiricial data) in terms of a function which is itself an integral of a product of two simpler functions (two polynomials), that is the model. ...
1
vote
0answers
59 views

FindFit with a sophisticated function (2), with corrected question and code

I am trying to find a fit to the distribution function (empiricial data) in terms of a function which is itself an integral of a product of two simplier functions. In particular, I observe T(x) (this ...
6
votes
1answer
193 views

FindFormula can't deal with the population data from Wolfram server

Bug introduced in 10.2 and fixed in 10.3 In the documentation of FindFormula, the first application of it is to predict the population of Poland. ...
6
votes
1answer
228 views

Default algorithm in NonlinearModelFit

Does anyone know the default algorithm used in NonlinearModelFit? The documentation gives several possible algorithms, but I can't figure out what it uses if you do not specify the algorithm. Thanks.
23
votes
4answers
1k views

Generating an “average curve” from a dense set of “semicontinuous curves” which clear trends

This question is related to a previous one of mine: Partitioning a superset of coordinates into subsets that generate continuous curves, where the challenge was to partition a data set into two ...
6
votes
2answers
3k views

NonlinearModelFit Problem

I have some problems with the NonlinearModelFit: NonlinearModelFit[data, A (1 + Cos[a x]) + B (1 + Cos[b x]) + c , {A, B, a, b, c}, x] The model should fit my ...
1
vote
1answer
107 views

FindFit algorithm?

Does anyone know how to program a mathematica algorithm that does the same thing that FindFit does? Is there documentation of it somewhere? I assume it is a least ...
13
votes
2answers
953 views

What is the difference between FindFit and NonlinearModelFit

I cannot get the difference between these two fitting functions in Mathematica. I even read in MMA that the result of these two are the same.
0
votes
0answers
31 views

EstimatedBackground function on Mathematica 9

Is there a way to replicate the EstimatedBackground function on Mathematica 9?
5
votes
3answers
242 views

Removing background from peak function

Let's say I have a a very large list of data in the format {{n,f[n]}} so something like {{1,600},{2,700},{3,1100}...} and if this data is plotted, then it will look like a sum of Gaussian functions+a ...
0
votes
0answers
61 views

Using the results of FindPeak in FindFit

Using FindPeak on some datapoints, I have found the positions and values of likely Gaussian peaks which form the data. The format is ...
1
vote
1answer
106 views

Using List/Histogram Data As A Weighted Function?

I have a list of data points that I would like to use as a weighted function. The data represents the number of particles within a bin of a particle distribution. Ultimately I would like to multiply ...
4
votes
1answer
76 views

Proper command to fit a distribution with data incomplete in a known way

Here is my scenario: got some data that I have to fit to a specific parametric family of probability distributions (cannot be changed). Data consist of several bunches of integers between, say, 0 and ...
1
vote
0answers
160 views

NonLinearFit running too slowly when the model contains an integral [closed]

I am new to Mathematica and am learning to use it. I have come up with the following situation where I have to fit the data. ...
3
votes
0answers
59 views
11
votes
1answer
219 views

How can the Theil-Sen estimator be made to work on larger datasets?

The Theil-Sen estimator finds the slope and intercept of a line passing through a set of points by calculating the median slope and median intercept of the set of lines passing through all possible ...
19
votes
4answers
2k views

Implementation of smoothing splines function

I have some problems in writing a module for spline smoothing. Actually, I have been trying for about two weeks. My listing is here: ...
2
votes
2answers
306 views

Help with NonLinearModelFit

I have a question about fitting data with a model. I have a quite complicated model, based on Arctans, modified Bessel functions, etc, that I want to fit to my data, a table of couples (minimal ...
0
votes
1answer
91 views

Meaning of << >> in Mathematica [duplicate]

I used NonlinearModelFit to fit some data and although Mathematica thinks it has got the result, the answer is enclosed in these double angular brackets. What does it mean? More importantly, I cannot ...
1
vote
1answer
183 views

Efficiency problem with least square algorithm (Error in both variables)

I was informing myself about the least square algorithms with errors in x and y. I found this post and the top answer wasn't ...
-2
votes
1answer
110 views

A piecewise function with way too many pieces

I'm currently calculating a periodic square wave current function to feed into a particle accelerator. It's a square wave that ramps up to a certain frequency and then drops back to the base frequency ...
8
votes
2answers
123 views

Behaviour of RegionDistance with Ellipse?

The data is: data = {{13, 60}, {36, 35}, {70, 29}, {106, 41}, {118, 72}, {94, 94}, {49, 99}, {24, 85}}; When I try to find a fit circle,So my method is work ...
0
votes
0answers
66 views

FindFit giving many errors when given model produced by ParametricNDSolveValue

I am trying to use FindFit to determine 7 parameters using 7 differential equations based on data imported from Excel. A sample of the data is: ...
34
votes
5answers
3k views

Fitting points to tilted, off-center ellipse

I have 24 x-y points that are supposed to form an ellipse. ...
0
votes
2answers
77 views

Fit a polynomial/curve to an NIntegrate result

I want to NIntegrate a function which also contains some parameter. In the end, I would like to plot the result as a function of one of these parameters. The thing ...
2
votes
2answers
179 views

BSpline or other curve through arbitrary ordered sequence of two-dimensional points

How does one create a BSplineCurve or other smooth curve passing through each point in an ordered list, where the curve may be non-simple, i.e., can double-back ...
1
vote
1answer
102 views

Problem with NIntegrate and FindFit [closed]

I fit the experimental curve with the model using the following equation, ...
1
vote
3answers
199 views

Fit dataset with customized discontinuous distribution

I have the following parametric CDF: F[x_, λ_, β_, γ_] = Piecewise[{ {0, x < 0}, {1 - (1 - β) E^(-x λ), 0 <= x < γ }, {1, x >= γ} }]; ...
1
vote
2answers
134 views

stop rule for Nonlinearfit and best fit

I want to understand the rule under which the function Nonlinearfit stops to give the final result. I know that if the number of iterations exceeds ...
1
vote
0answers
48 views

Problem with curve fit using integral [closed]

I need fitting a Langevin function on a experimental data, but one parameter must be firstly optimized by using a Lognormal distribution. The complete expression could be written as: The integrate ...
2
votes
1answer
67 views

Negative adjusted coefficients of determination - why?

I am trying to fit a polynomial function to some multi-dimensional data. However, I am getting a negative $R_{adj}^2$ as you can see: ...
1
vote
2answers
58 views

Find function to relate two lists of values

I know Mathematica has the FindFit function to determine the parameters of a known function that fits a sequence of points, but what if you do not know the relationship (linear, log, quadratic, etc)? ...
2
votes
2answers
118 views

Solving coupled ODEs with NDSolve to fit experimental data

I need to fit a multi-exponential data (Intensity x Time) using a model consisting of three differential equations. I want to find the parameters that gives the best fit to the experimental data. ...
2
votes
1answer
231 views

Non-linear curve fit problem

I am having a problem with making a fit to data in Mathematica, which may involve my understanding of the methods available. I am trying to fit the derivative of a Frota function (which is a Single ...
4
votes
2answers
143 views

Problem with fit on a numerical function

My question is related to a previous one: Problem with simple fit, where I had a problem to fit a simple analytic function $\dfrac{a}{\sqrt{b^2-x^2}}$. The solution proposed in Problem with simple ...
4
votes
2answers
99 views

Problem with a simple Fit

I have defined two functions to fit $\dfrac{a}{\sqrt{x^2-b^2}}$ and $\dfrac{a}{\sqrt{b^2-x^2}}$. ...
0
votes
0answers
29 views

Save lists to re-open with Mathematica [duplicate]

I want to save a result of a computation in a file to re-open then in Mathematica in a new session. What is the most efficient and simple way to do this? To be specific, I am using ...
5
votes
1answer
1k views

Linear regression with x and y errors

I have a question about finding a linear regression weighted with x and y errors. I found the answer provided by 0x4A4D in Estimate error on slope of linear regression given data with associated ...
7
votes
0answers
134 views

FindFormula Control [closed]

FindFormula is great start on the path to full symbolic regression and I realize it's level of development is only experimental at this stage. But if I happen to ...
1
vote
0answers
48 views

Evaluation of likelihood very slow

I am trying to implement a simple statistical model for the first time in Mathematica. My model is made my one random variable which is the sum of background and signal. Background is an exponential ...
2
votes
0answers
859 views

histogram fit for probability density [closed]

I am trying to fit the (probability density) histogram of some data with the exponential function, but I am having difficulties. My raw data are in file called ...
1
vote
1answer
169 views

non linear Least Squares with model function given by ODE's

I have to fit to experimental data a model function given by a linear combination of functions y1(t) and y2(t) a1*y1(t) + a2*y2(t) with a1 and a2 ...
15
votes
1answer
428 views

Using perpendicular offsets in FindFit

I want to use perpendicular offsets in the built-in FindFit function. Are there any possible ways or do I have to code everything by myself?
10
votes
1answer
330 views

Fittting data with combination of an unknown number of Gaussians

I have data that I want to fit with a constant plus a combination of Gaussians, with their actual number being one parameter of the fit (besides the average and the variance of every one of them). ...
7
votes
3answers
200 views

Fitting data with interdependence

I have an issue, of which I'm not sure it can be solved, with or without Mathematica. I feel as if it should be possible, but I'm quite clueless as to how. Some introduction is required. I'm working ...
0
votes
1answer
57 views

Extract coefficient from LinearModelFit [closed]

I want to know how to extract the coefficients from the result of LinearModelFit. The functions used to fit are complicated and being in different forms. For ...