# Questions tagged [fitting]

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

1,203 questions
Filter by
Sorted by
Tagged with
29 views

### Calculate and plot mean values of pairs of data points

I have a list of data points where there can be multiple y values for a given x value, e.g., {{0, 4}, {1, 2}, {1, 3}, {2, 3}}. I would like to Take the mean of the y values for each x value. Get a ...
39 views

### Non linear fit data

I am trying to fit this data with this two models. In the first one, the solution is too far from the exact values. In the second one, there is an error. Could you please help? ...
62 views

### Logistic fit of data

I would like to use LogitModelFit to find the logistic function to my data. The error I obtain is LogitModelFit::binrsp: The response values are expected to be ...
88 views

### How to correctly show the slope of a linear part on LogPlot

I need to plot an Interpolation function of one independent variable (only a 3kB file) on LogPlot and show the slope of its linear part together on the ...
52 views

### Why does the FindFormula result contain Abs in result?

If you look at the first example of FindFormula, why is the result Mathematica produces showing an Abs? Table[{x, N[x Sin[x]]}, {x, 0, 4, .3}] FindFormula[%, x] ...
48 views

50 views

### How can I define the following function for arbitray values of the arguments?

Consider the following function a[m_, l_] = 1/Log[m/l]; with this function I define ...
49 views

### How is CurvatureConfidenceRegion in FittedModel from NonlinearModelFit calculated?

I have a FittedModel from NonlinearModelFit for which the determination of the ...
55 views

### goodness of fit test for grouped data

I have the following grouped data: Can someone please tell me how to run a goodness of fit test to test if this data is from a normal distribution? I would like to do this without estimating the ...
72 views

### fitting a monotonic function?

Let's say I have a few points and derivatives given for a function and I'd like to find the best fit through the data, which is monotonic. For example, if I take a polynomial ansatz, I get ...
67 views

### What is the most efficient way to use the fitted models?

I'm generating a simple linear model ($y=mx+b$) by fitting to the background of some data, and then trying to plug in the x-values of the data I'm actually interested in. I'm a bit surprised that <...
99 views

### Cannot fit data

First up, I'm quite new to Mathematica so any hints on better code would be greatly appreciated. I have already asked the question connected to this code, but later I've found a mistake. Now I need to ...
105 views

### Plotting perpendicular lines to a contour plot (electric field from equipotential curves)

I'm currently working on a experiment about Electric Fields and Equipotential Curves. The problem is that I want to plot (estimate) the curves of electric field using the fact that every one of these ...
55 views

My code is ...
41 views

### Output of the trained neural network for a set of inputs

Sorry if this was too trivial but I want to get the output of the neural network I trained for the specific inputs that I feed. The notation I often saw was of TrainedNet[inp] kind. But when I use ...
41 views

### What does the following error message mean, in the context of NonlinearModelFit?

I am deliberately not including data or a model for this question, as I want a more general answer so that I may be able to trouble shoot this myself in the future. When performing a fit, usually a ...
64 views

### Regression to fit data with an integral equation

I have a set data and I know that this data are best fitted by the following equation, assuming that f($\tau$) is a log normal distribution and $M_{eq}$ = 1.5: \$M(t,\tau)= M_{eq} \int (1-e^{-t/\tau}) ...