# Questions tagged [fitting]

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

1,325 questions
Filter by
Sorted by
Tagged with
88 views

### Fitting nonlinear function does not converge but looks close to best fit

I'm having trouble fitting this transition temperature equation to my data. Physically speaking, the intensity should flatten out for T>Tc, which seems to be the biggest problem here. The equation I'...
92 views

### Getting errors from ParametricNDSolveValue

I am a newcomer to Mathematica (use ver 9.0). I just want to fit the experimental data to a system of odes' by using NonlinearModelFit. The data, contains time in the first column and product ...
94 views

### Goodness of fit : how to perform weighted Pearson test (or equivalent)?

I wish to perform goodness of fit. Currently I use NonLinearModelFit : ...
98 views

### Finding a fit with a specific mean squared error

I have a fit a data set to the following equation ...
115 views

137 views

### Why doesn't Mathematica completely draw the fit?

I have a question, and I really need your help, because I think I'm not understanding the reason... I have a potential model.. F[x_] := k x^n for the next ...
108 views

### Fitting a Curie-Weiss law function with a diverging point to a data

I would like to fit a function to some experimental data such that the extracted value of Curie temperature (Tc) describes the temperature at which the response flattens out to a constant value. ...
81 views

### How to fit a list of points to a certain form given error bands?

I am trying to fit a list of points to the form F/(1 - a*q^2 + b*q^4), where F is the value at zero of a function, which ...
180 views

### Why does ListSurfacePlot3D yield a different surface fit than using Python code for best-fit quadratic curve (2nd-order)?

Using the same data, I obtain different surface fits on Mathematica (using ListSurfacePlot3D) and Python (using a code for best-fit quadratic curve (2nd-order)). Here's my code on Mathematica: ...
63 views

### How to extract parameters from fitted model for ListSurfacePlot3D?

I would like to obtain the parameters used by Mathematica to create this surface fit of 3d data: ...
79 views

### BSpline vs natural spline [closed]

The BSpline in mathematica is defined mathematically here. These BSplines constitute basis for any Spline. But how do I define natural splines in mathematica, i.e. splines that are linear left of the ...
127 views

### Tangent point coordinates when the curve is a set of points

I want to find the coordinates of the tangent point between a convex curve and a line that passes from a point with known coordinates (0,b) ("efficient portfolio" ...
89 views

### Accessing nonlinear fit coefficients

I have performed a nonlinear fit onto a set of data according to the form $a+b\cos(2\pi x)+c\sin(2\pi x)+d\cos(4\pi x)+e\sin(4\pi x)$. How do I access the best fit parameters $a,b,c,d,e$, store them ...
51 views

### Why UnitCovert doesn't work with Fit?

I need to find the Hubble constant (Ho) in light years, from some data, the exercise tells me that the constant of the hubble is the slope of the line. data: r1 is in MegaParsecs. ...
107 views

### NonlinearModelFit returning imaginary numbers after fitting real data

I am getting problems when I try to use NonlinearModelFit to fit a squareroot-like function to a set of real data points. Here is the function: \begin{equation} \...
419 views

### NonlinearModelFit when the fitting function produces a discrete list of values?

Short Version: I have a parameterized function (the model) that returns a list of values. I have data that I want to fit this model to, optimizing those parameters, where the list position in the data ...
168 views

### How to find fit for this plot?

I have been trying to find an expression that properly models the following plot in Mathematica v9.0: I have tried modelling it as odd-degree polynomials using Fit,...
261 views

### Fitting multiple data with model and NDSolve with different initial conditions, and other shared parameters

I know that there are already questions about fitting multiple datasets and about NDSolve and about shared and non shared parameters, but I tried to apply them and some things are still not clear. ...
60 views

### Fitting system of differential rate equations to data

I am trying to fit a set of differential equations to experimental data, without luck so far. These are the data: ...
29 views

...
159 views

### How to do an exponential fit for this data?

Whenever I try to use FindFit or NonlinearModelFit for the data (shown below), I keep getting the following error thrown at me: ...
186 views

### What is FindFormula returning?

I was playing around with FindFormula and am experiencing some odd behavior. I am running MMA 12.0.0.0 on a Windows 10, x86 architecture - if that matters. ...
67 views

### find gravity acceleration (g) using FindFit

I need some help again, with this simple exercise: Use the data to determine g, but this time use the functional form T = 2 pi Sqrt[L/g] for the period T of a ...
147 views

### Fitting experimental data with a parametric function

How does one use a fitting routine such as NonlinearModelFit with a ParametricFunction? Example below: First let's generate some data: ...
71 views

### Help with NonlinearModelFit Error

I would like to ask if anybody can help me to find a way around solving this problem in Mathematica. I've tried solutions I found here but they don't seem to work. I need all the help I can get. ...
301 views

### Non Linear Model Fit - Fitting ODE to Data

Thank you everyone for your meaningful contributions! My Goal and Problem I'm trying to fit a particular ODE in a set of ODE's to experimental data. I've attempted to implement this by following the ...
201 views

### Estimating the uncertainty in the slope of a straight line given the uncertainty in the data points

Basically I have some datapoints on the form $(x_i,y_i)$ ...
96 views

### How to find a formula that models this plot? [duplicate]

Here is the data that I used to get this plot: ...
71 views

66 views

### Force FindFormula to avoid Piecewise in the result?

Is it possible to provide any arguments to FindFormula to force it to avoid using Piecewise in the result, but instead try to ...
62 views

### Selecting method and using Abs[] for FindFit

I'm trying to fit the following list data ...
44 views

### Getting a PDF from a NonlinearFitModel

With the help of @JimB, I could fit some experimental data with a CDF using NonLinearFitModel. The set of data is the following: ...
77 views

### How to generate two non-overlapping LogNormalDistribution and their CDF?

I'd like to know how to generate two LogNormalDistribution with the same standart deviation and, if possible, get the associated CDF. To contextualize, I'm trying ...
45 views

### How to fit experimental data with by numerical integration?

folks. I'm a begginer with Mathematica and all I know is just a few basics commands and i'm trying to improve it. I have this list of experimental data taken from a paper which describes the ...
81 views

### How to fit one function into the form of another?

I have a slightly complicated periodic function of one variable t, say g[t]. I want to do a least squares fit of that function ...
52 views

### Table and NonlinearModelFit

I am trying to make data and fit it tp a power law model. but it doesn't work. I don't know what the problem is. ...
68 views

### How can I fit a function to another function?

I want to fit the gaussian function to power law function from the end of gaussian fitting curve to the peak of it, ...
86 views

### Model for log-inear data

I am trying to fit the following data with y axis on a log scale. I used the following model to fit the data but without success. Can anyone help me suggest a proper model? ...
107 views

### LinearModelFit with Standardized data

I have a small data set of six points: ...
86 views

### Curve Fitting using known Points [closed]

In this answer, David Stork said that my question could be solved using "simple curve fitting with different numbers of even polynomial rank" in Mathematica. How would I do that (an equation that goes ...
69 views

### Problem with fit

I am trying to find a proper matching function for the following data set: ...
69 views

### Creating a prediction/distribution based on several years of data

So I have several years of data from a survey. For each year I've used FindDistribution and Predict to see if I can fit the data. Here's one example Where I used FindDistribution to get ...
179 views

### How to fit my data to an ode

Here is system of ODEs and data, where I am trying to use the real data to estimate some governing parameters. ...