Note
Go to the end to download the full example code.
Mueller matrix
Exemplary fit of the complete Mueller matrix of a SiO2 on Si measurement.
import elli
from elli.fitting import ParamsHist, fit_mueller_matrix
Read data
We load the data from an ascii file containing each of the mueller matrix elements. The wavelength range is cut to be in between 210 nm and 820 nm, to stay in the range of the provided literature values for Si. The data is expected to be in a pandas dataframe containing the columns Mxy, where x and y refer to the matrix element inside the mueller matrix. The data is scaled by the M11 element, such that \(M_{11} = 1\) for all wavelengths. To show the structure we print the MM dataframe. If you load your data from another source make sure it adheres to this form.
M11 M12 M13 M14 ... M41 M42 M43 M44
Wavelength ...
210.30366 1.0 -0.09147 -0.01241 -0.00614 ... 0.00986 0.00048 -0.95574 0.25821
210.76102 1.0 -0.10879 -0.01151 -0.00901 ... 0.00917 0.01319 -0.96899 0.24432
211.21834 1.0 -0.10639 -0.00694 -0.00475 ... 0.00712 0.00891 -0.96191 0.24986
211.67561 1.0 -0.11544 -0.02094 -0.00348 ... 0.01877 0.01726 -0.95951 0.25408
212.13284 1.0 -0.12199 0.02182 0.00480 ... -0.01790 -0.01957 -0.95493 0.28308
... ... ... ... ... ... ... ... ... ...
818.08934 1.0 -0.44285 -0.00048 -0.00288 ... 0.00292 -0.00276 -0.87949 0.15713
818.50589 1.0 -0.44301 0.00376 0.00118 ... -0.00159 -0.01090 -0.87876 0.16422
818.92240 1.0 -0.44245 0.00887 0.00626 ... -0.00585 -0.01388 -0.87960 0.16743
819.33886 1.0 -0.44406 -0.00646 -0.00610 ... 0.00882 0.00424 -0.87907 0.15105
819.75528 1.0 -0.44381 0.01170 0.00550 ... -0.00692 -0.01260 -0.87849 0.16637
[1396 rows x 16 columns]
Setting start parameters
Here we set the start parameters for the SiO2 cauchy dispersion and thickness of the layer.
params = ParamsHist()
params.add("SiO2_n0", value=1.452, min=-100, max=100, vary=True)
params.add("SiO2_n1", value=36.0, min=-40000, max=40000, vary=True)
params.add("SiO2_n2", value=0, min=-40000, max=40000, vary=True)
params.add("SiO2_k0", value=0, min=-100, max=100, vary=True)
params.add("SiO2_k1", value=0, min=-40000, max=40000, vary=True)
params.add("SiO2_k2", value=0, min=-40000, max=40000, vary=True)
params.add("SiO2_d", value=120, min=0, max=40000, vary=True)
Load silicon dispersion from the refractiveindexinfo database
You can load any material from the index
refractiveindex.info, which is
embedded into the software (so you may use it offline, too). Here, we
are interested in the literature values for the silicon substrate.
First we need to load the database with rii_db = elli.db.RII() and
then we can query it with rii_db.get_mat("Si", "Aspnes") to load
this
entry.
rii_db = elli.db.RII()
Si = rii_db.get_mat("Si", "Aspnes")
Building the model
Here the model is build and the experimental structure is returned. For details on this process please refer to the Basic usage example. When executed in an jupyter notebook this displays an interactive graph with which you can select the start parameters before fitting the data.
@fit_mueller_matrix(MM, params, display_single=False, sharex=True, full_scale=False)
def model(lbda, params):
SiO2 = elli.Cauchy(
params["SiO2_n0"],
params["SiO2_n1"],
params["SiO2_n2"],
params["SiO2_k0"],
params["SiO2_k1"],
params["SiO2_k2"],
).get_mat()
Layer = [elli.Layer(SiO2, params["SiO2_d"])]
return elli.Structure(elli.AIR, Layer, Si).evaluate(
lbda, 70, solver=elli.Solver4x4, propagator=elli.PropagatorExpm()
)
Plot & Fit the model
Here we plot the model at the initial parameter set vs. the experimental data.
model.plot()
FigureWidget({
'data': [{'line': {'color': '#636EFA', 'dash': 'solid'},
'name': 'M11 ',
'type': 'scatter',
'uid': '02889c0e-8099-4c75-afd1-6254d7086f43',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x',
'y': array([1., 1., 1., ..., 1., 1., 1.], shape=(1396,)),
'yaxis': 'y'},
{'line': {'color': '#636EFA', 'dash': 'dash'},
'name': 'M11 theory',
'type': 'scatter',
'uid': '11038a8b-c4d4-45d1-899f-7f264a7d5c9b',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x',
'y': array([1., 1., 1., ..., 1., 1., 1.], shape=(1396,)),
'yaxis': 'y'},
{'line': {'color': '#EF553B', 'dash': 'solid'},
'name': 'M12 ',
'type': 'scatter',
'uid': '05a11b0f-4fe1-42ef-a7a4-cf1889132cb5',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x2',
'y': array([-0.09147, -0.10879, -0.10639, ..., -0.44245, -0.44406, -0.44381],
shape=(1396,)),
'yaxis': 'y2'},
{'line': {'color': '#EF553B', 'dash': 'dash'},
'name': 'M12 theory',
'type': 'scatter',
'uid': '9a21e21d-c976-4254-b1d6-47fd12882efd',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x2',
'y': array([ 0.48855385, 0.48240998, 0.47406745, ..., -0.27742534, -0.27818747,
-0.27894785], shape=(1396,)),
'yaxis': 'y2'},
{'line': {'color': '#00CC96', 'dash': 'solid'},
'name': 'M13 ',
'type': 'scatter',
'uid': '05969363-1a82-4798-80bc-d69167f4067f',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x3',
'y': array([-0.01241, -0.01151, -0.00694, ..., 0.00887, -0.00646, 0.0117 ],
shape=(1396,)),
'yaxis': 'y3'},
{'line': {'color': '#00CC96', 'dash': 'dash'},
'name': 'M13 theory',
'type': 'scatter',
'uid': '382a42f6-52d0-4299-b216-c3c35b103a73',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x3',
'y': array([0., 0., 0., ..., 0., 0., 0.], shape=(1396,)),
'yaxis': 'y3'},
{'line': {'color': '#AB63FA', 'dash': 'solid'},
'name': 'M14 ',
'type': 'scatter',
'uid': '922bddfc-46be-4427-bda4-8fd243f04b32',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x4',
'y': array([-0.00614, -0.00901, -0.00475, ..., 0.00626, -0.0061 , 0.0055 ],
shape=(1396,)),
'yaxis': 'y4'},
{'line': {'color': '#AB63FA', 'dash': 'dash'},
'name': 'M14 theory',
'type': 'scatter',
'uid': '5f0f4e95-c3ba-4381-9ffe-709354795b69',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x4',
'y': array([0., 0., 0., ..., 0., 0., 0.], shape=(1396,)),
'yaxis': 'y4'},
{'line': {'color': '#FFA15A', 'dash': 'solid'},
'name': 'M21 ',
'type': 'scatter',
'uid': '315b1683-e2a8-46f5-8dca-5ebd4d21023d',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x5',
'y': array([-0.09605, -0.09754, -0.10761, ..., -0.44024, -0.44126, -0.44135],
shape=(1396,)),
'yaxis': 'y5'},
{'line': {'color': '#FFA15A', 'dash': 'dash'},
'name': 'M21 theory',
'type': 'scatter',
'uid': '4d81ee56-2d88-4bbd-a7c1-b6b691b0db32',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x5',
'y': array([ 0.48855385, 0.48240998, 0.47406745, ..., -0.27742534, -0.27818747,
-0.27894785], shape=(1396,)),
'yaxis': 'y5'},
{'line': {'color': '#19D3F3', 'dash': 'solid'},
'name': 'M22 ',
'type': 'scatter',
'uid': 'fc0d79f5-6b8a-41a0-93f7-05cc5d2c6050',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x6',
'y': array([0.99426, 0.99475, 0.99637, ..., 0.99723, 0.99661, 0.99606],
shape=(1396,)),
'yaxis': 'y6'},
{'line': {'color': '#19D3F3', 'dash': 'dash'},
'name': 'M22 theory',
'type': 'scatter',
'uid': 'cc6f56cc-bca1-4db6-8b61-a9dafba2fd19',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x6',
'y': array([1., 1., 1., ..., 1., 1., 1.], shape=(1396,)),
'yaxis': 'y6'},
{'line': {'color': '#FF6692', 'dash': 'solid'},
'name': 'M23 ',
'type': 'scatter',
'uid': 'cec19d15-eaec-4c10-9506-d7bb2b1fcc4e',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x7',
'y': array([-0.00364, -0.00427, -0.00207, ..., -0.00457, 0.00234, -0.00653],
shape=(1396,)),
'yaxis': 'y7'},
{'line': {'color': '#FF6692', 'dash': 'dash'},
'name': 'M23 theory',
'type': 'scatter',
'uid': 'a6036e4d-472c-44fe-ac65-6a021f1ddb87',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x7',
'y': array([0., 0., 0., ..., 0., 0., 0.], shape=(1396,)),
'yaxis': 'y7'},
{'line': {'color': '#B6E880', 'dash': 'solid'},
'name': 'M24 ',
'type': 'scatter',
'uid': '3fa61412-859c-4c2d-990d-3f3f4c9142cd',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x8',
'y': array([ 0.01084, -0.00325, 0.01123, ..., -0.00263, 0.00227, -0.00311],
shape=(1396,)),
'yaxis': 'y8'},
{'line': {'color': '#B6E880', 'dash': 'dash'},
'name': 'M24 theory',
'type': 'scatter',
'uid': '6946f01c-d081-492b-a447-73143944e77d',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x8',
'y': array([0., 0., 0., ..., 0., 0., 0.], shape=(1396,)),
'yaxis': 'y8'},
{'line': {'color': '#FF97FF', 'dash': 'solid'},
'name': 'M31 ',
'type': 'scatter',
'uid': '2fed544e-4dfb-42f0-ad90-94607c5d4c28',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x9',
'y': array([-0.00278, -0.00634, -0.00219, ..., 0.00055, -0.00105, 0.00037],
shape=(1396,)),
'yaxis': 'y9'},
{'line': {'color': '#FF97FF', 'dash': 'dash'},
'name': 'M31 theory',
'type': 'scatter',
'uid': 'add4ecaa-b9cf-4a6d-a133-4eddb7f9d5a3',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x9',
'y': array([0., 0., 0., ..., 0., 0., 0.], shape=(1396,)),
'yaxis': 'y9'},
{'line': {'color': '#FECB52', 'dash': 'solid'},
'name': 'M32 ',
'type': 'scatter',
'uid': '1a447a7e-72d6-486a-b67a-0c52d7d4e084',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x10',
'y': array([-0.00212, -0.00045, 0.0003 , ..., -0.0018 , -0.00042, 0.00037],
shape=(1396,)),
'yaxis': 'y10'},
{'line': {'color': '#FECB52', 'dash': 'dash'},
'name': 'M32 theory',
'type': 'scatter',
'uid': 'd24aa765-ed96-461d-868b-3f0a9a386369',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x10',
'y': array([0., 0., 0., ..., 0., 0., 0.], shape=(1396,)),
'yaxis': 'y10'},
{'line': {'color': '#636EFA', 'dash': 'solid'},
'name': 'M33 ',
'type': 'scatter',
'uid': '87d7498a-3097-4dbb-8155-309d30506c28',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x11',
'y': array([0.27283, 0.26726, 0.2728 , ..., 0.16236, 0.16271, 0.16255],
shape=(1396,)),
'yaxis': 'y11'},
{'line': {'color': '#636EFA', 'dash': 'dash'},
'name': 'M33 theory',
'type': 'scatter',
'uid': 'e6f212e5-506a-47cb-9008-813c6262465b',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x11',
'y': array([-0.78177026, -0.75168899, -0.71871123, ..., 0.20163327, 0.20156999,
0.20150625], shape=(1396,)),
'yaxis': 'y11'},
{'line': {'color': '#EF553B', 'dash': 'solid'},
'name': 'M34 ',
'type': 'scatter',
'uid': '79831c39-67bf-4507-9c47-89accfc6348a',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x12',
'y': array([0.95555, 0.9645 , 0.95821, ..., 0.87712, 0.87629, 0.87661],
shape=(1396,)),
'yaxis': 'y12'},
{'line': {'color': '#EF553B', 'dash': 'dash'},
'name': 'M34 theory',
'type': 'scatter',
'uid': 'e9720aa3-adb2-4127-b922-3f6dc0d6d267',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x12',
'y': array([0.38749245, 0.44971578, 0.50863958, ..., 0.93935042, 0.93913858,
0.93892669], shape=(1396,)),
'yaxis': 'y12'},
{'line': {'color': '#00CC96', 'dash': 'solid'},
'name': 'M41 ',
'type': 'scatter',
'uid': 'ead6574f-8639-43f2-b6c2-7265cde1927d',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x13',
'y': array([ 0.00986, 0.00917, 0.00712, ..., -0.00585, 0.00882, -0.00692],
shape=(1396,)),
'yaxis': 'y13'},
{'line': {'color': '#00CC96', 'dash': 'dash'},
'name': 'M41 theory',
'type': 'scatter',
'uid': '0f400ad9-28f7-4eb2-ad16-5fb11326901a',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x13',
'y': array([0., 0., 0., ..., 0., 0., 0.], shape=(1396,)),
'yaxis': 'y13'},
{'line': {'color': '#AB63FA', 'dash': 'solid'},
'name': 'M42 ',
'type': 'scatter',
'uid': '845122f4-63d8-4a77-9ce6-fa3e8b842451',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x14',
'y': array([ 0.00048, 0.01319, 0.00891, ..., -0.01388, 0.00424, -0.0126 ],
shape=(1396,)),
'yaxis': 'y14'},
{'line': {'color': '#AB63FA', 'dash': 'dash'},
'name': 'M42 theory',
'type': 'scatter',
'uid': '2c8d9dac-232f-46be-ae3e-c1be620d7821',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x14',
'y': array([0., 0., 0., ..., 0., 0., 0.], shape=(1396,)),
'yaxis': 'y14'},
{'line': {'color': '#FFA15A', 'dash': 'solid'},
'name': 'M43 ',
'type': 'scatter',
'uid': '6faf21fa-a36c-46ca-ab60-2a1a03d175d2',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x15',
'y': array([-0.95574, -0.96899, -0.96191, ..., -0.8796 , -0.87907, -0.87849],
shape=(1396,)),
'yaxis': 'y15'},
{'line': {'color': '#FFA15A', 'dash': 'dash'},
'name': 'M43 theory',
'type': 'scatter',
'uid': '0edac1ff-de85-4a11-a981-ee9075b73217',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x15',
'y': array([-0.38749245, -0.44971578, -0.50863958, ..., -0.93935042, -0.93913858,
-0.93892669], shape=(1396,)),
'yaxis': 'y15'},
{'line': {'color': '#19D3F3', 'dash': 'solid'},
'name': 'M44 ',
'type': 'scatter',
'uid': 'b05d8591-04fd-4128-9595-1d0d0e50123c',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x16',
'y': array([0.25821, 0.24432, 0.24986, ..., 0.16743, 0.15105, 0.16637],
shape=(1396,)),
'yaxis': 'y16'},
{'line': {'color': '#19D3F3', 'dash': 'dash'},
'name': 'M44 theory',
'type': 'scatter',
'uid': 'ad66de32-9718-4194-8a2d-e8c2398ee136',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x16',
'y': array([-0.78177026, -0.75168899, -0.71871123, ..., 0.20163327, 0.20156999,
0.20150625], shape=(1396,)),
'yaxis': 'y16'}],
'layout': {'template': '...',
'xaxis': {'anchor': 'y', 'domain': [0.0, 0.2125], 'matches': 'x'},
'xaxis10': {'anchor': 'y10', 'domain': [0.2625, 0.475], 'matches': 'x'},
'xaxis11': {'anchor': 'y11', 'domain': [0.525, 0.7375], 'matches': 'x'},
'xaxis12': {'anchor': 'y12', 'domain': [0.7875, 1.0], 'matches': 'x'},
'xaxis13': {'anchor': 'y13', 'domain': [0.0, 0.2125], 'matches': 'x'},
'xaxis14': {'anchor': 'y14', 'domain': [0.2625, 0.475], 'matches': 'x'},
'xaxis15': {'anchor': 'y15', 'domain': [0.525, 0.7375], 'matches': 'x'},
'xaxis16': {'anchor': 'y16', 'domain': [0.7875, 1.0], 'matches': 'x'},
'xaxis2': {'anchor': 'y2', 'domain': [0.2625, 0.475], 'matches': 'x'},
'xaxis3': {'anchor': 'y3', 'domain': [0.525, 0.7375], 'matches': 'x'},
'xaxis4': {'anchor': 'y4', 'domain': [0.7875, 1.0], 'matches': 'x'},
'xaxis5': {'anchor': 'y5', 'domain': [0.0, 0.2125], 'matches': 'x'},
'xaxis6': {'anchor': 'y6', 'domain': [0.2625, 0.475], 'matches': 'x'},
'xaxis7': {'anchor': 'y7', 'domain': [0.525, 0.7375], 'matches': 'x'},
'xaxis8': {'anchor': 'y8', 'domain': [0.7875, 1.0], 'matches': 'x'},
'xaxis9': {'anchor': 'y9', 'domain': [0.0, 0.2125], 'matches': 'x'},
'yaxis': {'anchor': 'x', 'domain': [0.80625, 1.0]},
'yaxis10': {'anchor': 'x10', 'domain': [0.26875, 0.4625]},
'yaxis11': {'anchor': 'x11', 'domain': [0.26875, 0.4625]},
'yaxis12': {'anchor': 'x12', 'domain': [0.26875, 0.4625]},
'yaxis13': {'anchor': 'x13', 'domain': [0.0, 0.19375]},
'yaxis14': {'anchor': 'x14', 'domain': [0.0, 0.19375]},
'yaxis15': {'anchor': 'x15', 'domain': [0.0, 0.19375]},
'yaxis16': {'anchor': 'x16', 'domain': [0.0, 0.19375]},
'yaxis2': {'anchor': 'x2', 'domain': [0.80625, 1.0]},
'yaxis3': {'anchor': 'x3', 'domain': [0.80625, 1.0]},
'yaxis4': {'anchor': 'x4', 'domain': [0.80625, 1.0]},
'yaxis5': {'anchor': 'x5', 'domain': [0.5375, 0.73125]},
'yaxis6': {'anchor': 'x6', 'domain': [0.5375, 0.73125]},
'yaxis7': {'anchor': 'x7', 'domain': [0.5375, 0.73125]},
'yaxis8': {'anchor': 'x8', 'domain': [0.5375, 0.73125]},
'yaxis9': {'anchor': 'x9', 'domain': [0.26875, 0.4625]}}
})
We can also plot the residual between measurement and model.
model.plot_residual()
FigureWidget({
'data': [{'line': {'color': '#636EFA', 'dash': 'solid'},
'name': 'M11 ',
'type': 'scatter',
'uid': 'ed0eff86-4bee-4cc7-8ac4-d0a96f4e70b9',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x',
'y': array([0., 0., 0., ..., 0., 0., 0.], shape=(1396,)),
'yaxis': 'y'},
{'line': {'color': '#EF553B', 'dash': 'solid'},
'name': 'M12 ',
'type': 'scatter',
'uid': 'f80beeac-49e9-4557-b2b5-4876a68543e8',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x2',
'y': array([0.58002385, 0.59119998, 0.58045745, ..., 0.16502466, 0.16587253,
0.16486215], shape=(1396,)),
'yaxis': 'y2'},
{'line': {'color': '#00CC96', 'dash': 'solid'},
'name': 'M13 ',
'type': 'scatter',
'uid': '77e1f275-1b83-4ddb-942c-1b6ebced3543',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x3',
'y': array([ 0.01241, 0.01151, 0.00694, ..., -0.00887, 0.00646, -0.0117 ],
shape=(1396,)),
'yaxis': 'y3'},
{'line': {'color': '#AB63FA', 'dash': 'solid'},
'name': 'M14 ',
'type': 'scatter',
'uid': 'b69ba3ce-7608-4343-b6b8-7e0ba4d78be9',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x4',
'y': array([ 0.00614, 0.00901, 0.00475, ..., -0.00626, 0.0061 , -0.0055 ],
shape=(1396,)),
'yaxis': 'y4'},
{'line': {'color': '#FFA15A', 'dash': 'solid'},
'name': 'M21 ',
'type': 'scatter',
'uid': 'd2455b9a-940b-43a7-a072-920c34f60316',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x5',
'y': array([0.58460385, 0.57994998, 0.58167745, ..., 0.16281466, 0.16307253,
0.16240215], shape=(1396,)),
'yaxis': 'y5'},
{'line': {'color': '#19D3F3', 'dash': 'solid'},
'name': 'M22 ',
'type': 'scatter',
'uid': '38b419f6-dd8d-4f4e-af43-837ef9c7fcb2',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x6',
'y': array([0.00574, 0.00525, 0.00363, ..., 0.00277, 0.00339, 0.00394],
shape=(1396,)),
'yaxis': 'y6'},
{'line': {'color': '#FF6692', 'dash': 'solid'},
'name': 'M23 ',
'type': 'scatter',
'uid': 'a5356ee1-017d-4733-b599-5b4dc5a05d3c',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x7',
'y': array([ 0.00364, 0.00427, 0.00207, ..., 0.00457, -0.00234, 0.00653],
shape=(1396,)),
'yaxis': 'y7'},
{'line': {'color': '#B6E880', 'dash': 'solid'},
'name': 'M24 ',
'type': 'scatter',
'uid': 'ec9e2ea0-d1ac-4942-9f37-5f9063d1faad',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x8',
'y': array([-0.01084, 0.00325, -0.01123, ..., 0.00263, -0.00227, 0.00311],
shape=(1396,)),
'yaxis': 'y8'},
{'line': {'color': '#FF97FF', 'dash': 'solid'},
'name': 'M31 ',
'type': 'scatter',
'uid': '09a67672-d9e3-4825-b784-55133c9385db',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x9',
'y': array([ 0.00278, 0.00634, 0.00219, ..., -0.00055, 0.00105, -0.00037],
shape=(1396,)),
'yaxis': 'y9'},
{'line': {'color': '#FECB52', 'dash': 'solid'},
'name': 'M32 ',
'type': 'scatter',
'uid': '4a0769b9-0ff8-4978-a1d2-3e5b7765ccf8',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x10',
'y': array([ 0.00212, 0.00045, -0.0003 , ..., 0.0018 , 0.00042, -0.00037],
shape=(1396,)),
'yaxis': 'y10'},
{'line': {'color': '#636EFA', 'dash': 'solid'},
'name': 'M33 ',
'type': 'scatter',
'uid': 'ce551563-7d39-4e20-b110-7a4aa188e23d',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x11',
'y': array([-1.05460026, -1.01894899, -0.99151123, ..., 0.03927327, 0.03885999,
0.03895625], shape=(1396,)),
'yaxis': 'y11'},
{'line': {'color': '#EF553B', 'dash': 'solid'},
'name': 'M34 ',
'type': 'scatter',
'uid': '9a0c56fe-9d4a-40f0-96e1-cca12e2d26da',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x12',
'y': array([-0.56805755, -0.51478422, -0.44957042, ..., 0.06223042, 0.06284858,
0.06231669], shape=(1396,)),
'yaxis': 'y12'},
{'line': {'color': '#00CC96', 'dash': 'solid'},
'name': 'M41 ',
'type': 'scatter',
'uid': '0cb105c0-099d-4420-b5d4-1a60932dce18',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x13',
'y': array([-0.00986, -0.00917, -0.00712, ..., 0.00585, -0.00882, 0.00692],
shape=(1396,)),
'yaxis': 'y13'},
{'line': {'color': '#AB63FA', 'dash': 'solid'},
'name': 'M42 ',
'type': 'scatter',
'uid': '9836785c-e28d-4fd7-9342-1690cf942b45',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x14',
'y': array([-0.00048, -0.01319, -0.00891, ..., 0.01388, -0.00424, 0.0126 ],
shape=(1396,)),
'yaxis': 'y14'},
{'line': {'color': '#FFA15A', 'dash': 'solid'},
'name': 'M43 ',
'type': 'scatter',
'uid': '6a940511-4c93-4461-a96f-7fc23fb8fb02',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x15',
'y': array([ 0.56824755, 0.51927422, 0.45327042, ..., -0.05975042, -0.06006858,
-0.06043669], shape=(1396,)),
'yaxis': 'y15'},
{'line': {'color': '#19D3F3', 'dash': 'solid'},
'name': 'M44 ',
'type': 'scatter',
'uid': '6f0d2b2f-1bba-4f69-915b-1276e33c0439',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x16',
'y': array([-1.03998026, -0.99600899, -0.96857123, ..., 0.03420327, 0.05051999,
0.03513625], shape=(1396,)),
'yaxis': 'y16'}],
'layout': {'template': '...',
'xaxis': {'anchor': 'y', 'domain': [0.0, 0.2125], 'matches': 'x'},
'xaxis10': {'anchor': 'y10', 'domain': [0.2625, 0.475], 'matches': 'x'},
'xaxis11': {'anchor': 'y11', 'domain': [0.525, 0.7375], 'matches': 'x'},
'xaxis12': {'anchor': 'y12', 'domain': [0.7875, 1.0], 'matches': 'x'},
'xaxis13': {'anchor': 'y13', 'domain': [0.0, 0.2125], 'matches': 'x'},
'xaxis14': {'anchor': 'y14', 'domain': [0.2625, 0.475], 'matches': 'x'},
'xaxis15': {'anchor': 'y15', 'domain': [0.525, 0.7375], 'matches': 'x'},
'xaxis16': {'anchor': 'y16', 'domain': [0.7875, 1.0], 'matches': 'x'},
'xaxis2': {'anchor': 'y2', 'domain': [0.2625, 0.475], 'matches': 'x'},
'xaxis3': {'anchor': 'y3', 'domain': [0.525, 0.7375], 'matches': 'x'},
'xaxis4': {'anchor': 'y4', 'domain': [0.7875, 1.0], 'matches': 'x'},
'xaxis5': {'anchor': 'y5', 'domain': [0.0, 0.2125], 'matches': 'x'},
'xaxis6': {'anchor': 'y6', 'domain': [0.2625, 0.475], 'matches': 'x'},
'xaxis7': {'anchor': 'y7', 'domain': [0.525, 0.7375], 'matches': 'x'},
'xaxis8': {'anchor': 'y8', 'domain': [0.7875, 1.0], 'matches': 'x'},
'xaxis9': {'anchor': 'y9', 'domain': [0.0, 0.2125], 'matches': 'x'},
'yaxis': {'anchor': 'x', 'domain': [0.80625, 1.0]},
'yaxis10': {'anchor': 'x10', 'domain': [0.26875, 0.4625]},
'yaxis11': {'anchor': 'x11', 'domain': [0.26875, 0.4625]},
'yaxis12': {'anchor': 'x12', 'domain': [0.26875, 0.4625]},
'yaxis13': {'anchor': 'x13', 'domain': [0.0, 0.19375]},
'yaxis14': {'anchor': 'x14', 'domain': [0.0, 0.19375]},
'yaxis15': {'anchor': 'x15', 'domain': [0.0, 0.19375]},
'yaxis16': {'anchor': 'x16', 'domain': [0.0, 0.19375]},
'yaxis2': {'anchor': 'x2', 'domain': [0.80625, 1.0]},
'yaxis3': {'anchor': 'x3', 'domain': [0.80625, 1.0]},
'yaxis4': {'anchor': 'x4', 'domain': [0.80625, 1.0]},
'yaxis5': {'anchor': 'x5', 'domain': [0.5375, 0.73125]},
'yaxis6': {'anchor': 'x6', 'domain': [0.5375, 0.73125]},
'yaxis7': {'anchor': 'x7', 'domain': [0.5375, 0.73125]},
'yaxis8': {'anchor': 'x8', 'domain': [0.5375, 0.73125]},
'yaxis9': {'anchor': 'x9', 'domain': [0.26875, 0.4625]}}
})
Now we execute a fit and plot the model afterwards.
fit_stats = model.fit()
model.plot(full_scale=False)
FigureWidget({
'data': [{'line': {'color': '#636EFA', 'dash': 'solid'},
'name': 'M11 ',
'type': 'scatter',
'uid': 'c77ec689-d071-4d2f-bbd3-994ab9405c79',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x',
'y': array([1., 1., 1., ..., 1., 1., 1.], shape=(1396,)),
'yaxis': 'y'},
{'line': {'color': '#636EFA', 'dash': 'dash'},
'name': 'M11 theory',
'type': 'scatter',
'uid': 'cf277203-72b9-405a-ab77-3342d14a2dec',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x',
'y': array([1., 1., 1., ..., 1., 1., 1.], shape=(1396,)),
'yaxis': 'y'},
{'line': {'color': '#EF553B', 'dash': 'solid'},
'name': 'M12 ',
'type': 'scatter',
'uid': '437058a7-b0b1-47aa-a4b8-468d0b230406',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x2',
'y': array([-0.09147, -0.10879, -0.10639, ..., -0.44245, -0.44406, -0.44381],
shape=(1396,)),
'yaxis': 'y2'},
{'line': {'color': '#EF553B', 'dash': 'dash'},
'name': 'M12 theory',
'type': 'scatter',
'uid': 'ed58311a-2bbe-4296-8f63-bb81b7d523ed',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x2',
'y': array([-0.09081776, -0.09659845, -0.10218436, ..., -0.44726608, -0.44776779,
-0.44826863], shape=(1396,)),
'yaxis': 'y2'},
{'line': {'color': '#00CC96', 'dash': 'solid'},
'name': 'M13 ',
'type': 'scatter',
'uid': 'eb813253-956d-4125-a5ed-9c451a62423d',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x3',
'y': array([-0.01241, -0.01151, -0.00694, ..., 0.00887, -0.00646, 0.0117 ],
shape=(1396,)),
'yaxis': 'y3'},
{'line': {'color': '#00CC96', 'dash': 'dash'},
'name': 'M13 theory',
'type': 'scatter',
'uid': '3454d209-2dc4-4429-98da-694a182e5b2b',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x3',
'y': array([0., 0., 0., ..., 0., 0., 0.], shape=(1396,)),
'yaxis': 'y3'},
{'line': {'color': '#AB63FA', 'dash': 'solid'},
'name': 'M14 ',
'type': 'scatter',
'uid': 'bf128587-3bc5-4703-891e-ffcb38f9a8a0',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x4',
'y': array([-0.00614, -0.00901, -0.00475, ..., 0.00626, -0.0061 , 0.0055 ],
shape=(1396,)),
'yaxis': 'y4'},
{'line': {'color': '#AB63FA', 'dash': 'dash'},
'name': 'M14 theory',
'type': 'scatter',
'uid': '6c341e28-dabc-4938-9015-0d63b90016ca',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x4',
'y': array([0., 0., 0., ..., 0., 0., 0.], shape=(1396,)),
'yaxis': 'y4'},
{'line': {'color': '#FFA15A', 'dash': 'solid'},
'name': 'M21 ',
'type': 'scatter',
'uid': '059960a2-ef50-4e04-8be1-bf13017f6dc6',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x5',
'y': array([-0.09605, -0.09754, -0.10761, ..., -0.44024, -0.44126, -0.44135],
shape=(1396,)),
'yaxis': 'y5'},
{'line': {'color': '#FFA15A', 'dash': 'dash'},
'name': 'M21 theory',
'type': 'scatter',
'uid': '9897539a-59b7-4c6e-a150-2dbfbe9c4908',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x5',
'y': array([-0.09081776, -0.09659845, -0.10218436, ..., -0.44726608, -0.44776779,
-0.44826863], shape=(1396,)),
'yaxis': 'y5'},
{'line': {'color': '#19D3F3', 'dash': 'solid'},
'name': 'M22 ',
'type': 'scatter',
'uid': '2d960c9b-3b2d-47d7-9a04-32e411124344',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x6',
'y': array([0.99426, 0.99475, 0.99637, ..., 0.99723, 0.99661, 0.99606],
shape=(1396,)),
'yaxis': 'y6'},
{'line': {'color': '#19D3F3', 'dash': 'dash'},
'name': 'M22 theory',
'type': 'scatter',
'uid': '578e454f-1c50-4838-8a98-c337785c61fb',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x6',
'y': array([1., 1., 1., ..., 1., 1., 1.], shape=(1396,)),
'yaxis': 'y6'},
{'line': {'color': '#FF6692', 'dash': 'solid'},
'name': 'M23 ',
'type': 'scatter',
'uid': 'b7aa0bfe-76ba-4bed-b55e-90a57127bc4a',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x7',
'y': array([-0.00364, -0.00427, -0.00207, ..., -0.00457, 0.00234, -0.00653],
shape=(1396,)),
'yaxis': 'y7'},
{'line': {'color': '#FF6692', 'dash': 'dash'},
'name': 'M23 theory',
'type': 'scatter',
'uid': '83234011-a306-485d-9780-9850196072c6',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x7',
'y': array([0., 0., 0., ..., 0., 0., 0.], shape=(1396,)),
'yaxis': 'y7'},
{'line': {'color': '#B6E880', 'dash': 'solid'},
'name': 'M24 ',
'type': 'scatter',
'uid': '425b948b-68f1-499c-8d7c-021dadca0f36',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x8',
'y': array([ 0.01084, -0.00325, 0.01123, ..., -0.00263, 0.00227, -0.00311],
shape=(1396,)),
'yaxis': 'y8'},
{'line': {'color': '#B6E880', 'dash': 'dash'},
'name': 'M24 theory',
'type': 'scatter',
'uid': '38690102-64f8-4a77-b186-9638c78ec687',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x8',
'y': array([0., 0., 0., ..., 0., 0., 0.], shape=(1396,)),
'yaxis': 'y8'},
{'line': {'color': '#FF97FF', 'dash': 'solid'},
'name': 'M31 ',
'type': 'scatter',
'uid': 'fd785b8a-ce7e-473c-9be5-bf7bc0ad5465',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x9',
'y': array([-0.00278, -0.00634, -0.00219, ..., 0.00055, -0.00105, 0.00037],
shape=(1396,)),
'yaxis': 'y9'},
{'line': {'color': '#FF97FF', 'dash': 'dash'},
'name': 'M31 theory',
'type': 'scatter',
'uid': '11cb966f-4d01-4bbe-b8fd-58d465fc2208',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x9',
'y': array([0., 0., 0., ..., 0., 0., 0.], shape=(1396,)),
'yaxis': 'y9'},
{'line': {'color': '#FECB52', 'dash': 'solid'},
'name': 'M32 ',
'type': 'scatter',
'uid': 'dd6d7923-4cd7-4ead-bb07-175079dc8ce4',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x10',
'y': array([-0.00212, -0.00045, 0.0003 , ..., -0.0018 , -0.00042, 0.00037],
shape=(1396,)),
'yaxis': 'y10'},
{'line': {'color': '#FECB52', 'dash': 'dash'},
'name': 'M32 theory',
'type': 'scatter',
'uid': '2f839c9a-c6ae-460a-9a7f-f598466e920e',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x10',
'y': array([0., 0., 0., ..., 0., 0., 0.], shape=(1396,)),
'yaxis': 'y10'},
{'line': {'color': '#636EFA', 'dash': 'solid'},
'name': 'M33 ',
'type': 'scatter',
'uid': 'f16988c7-3f93-4b2a-9f82-b164bda8f4e3',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x11',
'y': array([0.27283, 0.26726, 0.2728 , ..., 0.16236, 0.16271, 0.16255],
shape=(1396,)),
'yaxis': 'y11'},
{'line': {'color': '#636EFA', 'dash': 'dash'},
'name': 'M33 theory',
'type': 'scatter',
'uid': '5280c7cb-a86e-4bd7-bc8a-e1d4cf2b1644',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x11',
'y': array([0.28633493, 0.28495866, 0.28318747, ..., 0.15873433, 0.1585769 ,
0.15841941], shape=(1396,)),
'yaxis': 'y11'},
{'line': {'color': '#EF553B', 'dash': 'solid'},
'name': 'M34 ',
'type': 'scatter',
'uid': '6300e1ef-d732-4a63-94ca-a9efb5603973',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x12',
'y': array([0.95555, 0.9645 , 0.95821, ..., 0.87712, 0.87629, 0.87661],
shape=(1396,)),
'yaxis': 'y12'},
{'line': {'color': '#EF553B', 'dash': 'dash'},
'name': 'M34 theory',
'type': 'scatter',
'uid': '5edc665b-f98a-4343-872e-08b2bdb5182c',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x12',
'y': array([0.95381573, 0.95365995, 0.95360538, ..., 0.88020251, 0.87997578,
0.87974912], shape=(1396,)),
'yaxis': 'y12'},
{'line': {'color': '#00CC96', 'dash': 'solid'},
'name': 'M41 ',
'type': 'scatter',
'uid': '682f3c8b-bafe-4911-90bd-424d46bf6080',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x13',
'y': array([ 0.00986, 0.00917, 0.00712, ..., -0.00585, 0.00882, -0.00692],
shape=(1396,)),
'yaxis': 'y13'},
{'line': {'color': '#00CC96', 'dash': 'dash'},
'name': 'M41 theory',
'type': 'scatter',
'uid': 'c49d591b-459c-4e69-8601-0f53b7a98b47',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x13',
'y': array([0., 0., 0., ..., 0., 0., 0.], shape=(1396,)),
'yaxis': 'y13'},
{'line': {'color': '#AB63FA', 'dash': 'solid'},
'name': 'M42 ',
'type': 'scatter',
'uid': '1068f6dd-9a23-48c9-910d-ee57561848d1',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x14',
'y': array([ 0.00048, 0.01319, 0.00891, ..., -0.01388, 0.00424, -0.0126 ],
shape=(1396,)),
'yaxis': 'y14'},
{'line': {'color': '#AB63FA', 'dash': 'dash'},
'name': 'M42 theory',
'type': 'scatter',
'uid': '5f5a6fe5-7ae2-4760-80e2-52835c3b75cd',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x14',
'y': array([0., 0., 0., ..., 0., 0., 0.], shape=(1396,)),
'yaxis': 'y14'},
{'line': {'color': '#FFA15A', 'dash': 'solid'},
'name': 'M43 ',
'type': 'scatter',
'uid': 'f6eb9029-4dca-4e84-aab1-2f999a9760f6',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x15',
'y': array([-0.95574, -0.96899, -0.96191, ..., -0.8796 , -0.87907, -0.87849],
shape=(1396,)),
'yaxis': 'y15'},
{'line': {'color': '#FFA15A', 'dash': 'dash'},
'name': 'M43 theory',
'type': 'scatter',
'uid': '33c15a38-47c0-4d83-b4f1-fbdf1427b84b',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x15',
'y': array([-0.95381573, -0.95365995, -0.95360538, ..., -0.88020251, -0.87997578,
-0.87974912], shape=(1396,)),
'yaxis': 'y15'},
{'line': {'color': '#19D3F3', 'dash': 'solid'},
'name': 'M44 ',
'type': 'scatter',
'uid': 'd11b0672-0293-43da-bb81-b949f21ab211',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x16',
'y': array([0.25821, 0.24432, 0.24986, ..., 0.16743, 0.15105, 0.16637],
shape=(1396,)),
'yaxis': 'y16'},
{'line': {'color': '#19D3F3', 'dash': 'dash'},
'name': 'M44 theory',
'type': 'scatter',
'uid': 'd3fe2f79-3519-44df-a84a-6281a60ef807',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x16',
'y': array([0.28633493, 0.28495866, 0.28318747, ..., 0.15873433, 0.1585769 ,
0.15841941], shape=(1396,)),
'yaxis': 'y16'}],
'layout': {'template': '...',
'xaxis': {'anchor': 'y', 'domain': [0.0, 0.2125], 'matches': 'x'},
'xaxis10': {'anchor': 'y10', 'domain': [0.2625, 0.475], 'matches': 'x'},
'xaxis11': {'anchor': 'y11', 'domain': [0.525, 0.7375], 'matches': 'x'},
'xaxis12': {'anchor': 'y12', 'domain': [0.7875, 1.0], 'matches': 'x'},
'xaxis13': {'anchor': 'y13', 'domain': [0.0, 0.2125], 'matches': 'x'},
'xaxis14': {'anchor': 'y14', 'domain': [0.2625, 0.475], 'matches': 'x'},
'xaxis15': {'anchor': 'y15', 'domain': [0.525, 0.7375], 'matches': 'x'},
'xaxis16': {'anchor': 'y16', 'domain': [0.7875, 1.0], 'matches': 'x'},
'xaxis2': {'anchor': 'y2', 'domain': [0.2625, 0.475], 'matches': 'x'},
'xaxis3': {'anchor': 'y3', 'domain': [0.525, 0.7375], 'matches': 'x'},
'xaxis4': {'anchor': 'y4', 'domain': [0.7875, 1.0], 'matches': 'x'},
'xaxis5': {'anchor': 'y5', 'domain': [0.0, 0.2125], 'matches': 'x'},
'xaxis6': {'anchor': 'y6', 'domain': [0.2625, 0.475], 'matches': 'x'},
'xaxis7': {'anchor': 'y7', 'domain': [0.525, 0.7375], 'matches': 'x'},
'xaxis8': {'anchor': 'y8', 'domain': [0.7875, 1.0], 'matches': 'x'},
'xaxis9': {'anchor': 'y9', 'domain': [0.0, 0.2125], 'matches': 'x'},
'yaxis': {'anchor': 'x', 'domain': [0.80625, 1.0]},
'yaxis10': {'anchor': 'x10', 'domain': [0.26875, 0.4625]},
'yaxis11': {'anchor': 'x11', 'domain': [0.26875, 0.4625]},
'yaxis12': {'anchor': 'x12', 'domain': [0.26875, 0.4625]},
'yaxis13': {'anchor': 'x13', 'domain': [0.0, 0.19375]},
'yaxis14': {'anchor': 'x14', 'domain': [0.0, 0.19375]},
'yaxis15': {'anchor': 'x15', 'domain': [0.0, 0.19375]},
'yaxis16': {'anchor': 'x16', 'domain': [0.0, 0.19375]},
'yaxis2': {'anchor': 'x2', 'domain': [0.80625, 1.0]},
'yaxis3': {'anchor': 'x3', 'domain': [0.80625, 1.0]},
'yaxis4': {'anchor': 'x4', 'domain': [0.80625, 1.0]},
'yaxis5': {'anchor': 'x5', 'domain': [0.5375, 0.73125]},
'yaxis6': {'anchor': 'x6', 'domain': [0.5375, 0.73125]},
'yaxis7': {'anchor': 'x7', 'domain': [0.5375, 0.73125]},
'yaxis8': {'anchor': 'x8', 'domain': [0.5375, 0.73125]},
'yaxis9': {'anchor': 'x9', 'domain': [0.26875, 0.4625]}}
})
For comparison we plot the residual again to have a figure of merit for the fit quality
model.plot_residual()
FigureWidget({
'data': [{'line': {'color': '#636EFA', 'dash': 'solid'},
'name': 'M11 ',
'type': 'scatter',
'uid': 'f9d23430-230a-4684-9426-dd164fcb2664',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x',
'y': array([0., 0., 0., ..., 0., 0., 0.], shape=(1396,)),
'yaxis': 'y'},
{'line': {'color': '#EF553B', 'dash': 'solid'},
'name': 'M12 ',
'type': 'scatter',
'uid': 'a1974023-0343-4a04-af52-43a7bf354141',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x2',
'y': array([ 0.00065224, 0.01219155, 0.00420564, ..., -0.00481608, -0.00370779,
-0.00445863], shape=(1396,)),
'yaxis': 'y2'},
{'line': {'color': '#00CC96', 'dash': 'solid'},
'name': 'M13 ',
'type': 'scatter',
'uid': 'e5967972-7831-4389-a9ae-f4c4dfbbb852',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x3',
'y': array([ 0.01241, 0.01151, 0.00694, ..., -0.00887, 0.00646, -0.0117 ],
shape=(1396,)),
'yaxis': 'y3'},
{'line': {'color': '#AB63FA', 'dash': 'solid'},
'name': 'M14 ',
'type': 'scatter',
'uid': 'e779b811-2ecf-48ed-83ef-a4f7ab361b75',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x4',
'y': array([ 0.00614, 0.00901, 0.00475, ..., -0.00626, 0.0061 , -0.0055 ],
shape=(1396,)),
'yaxis': 'y4'},
{'line': {'color': '#FFA15A', 'dash': 'solid'},
'name': 'M21 ',
'type': 'scatter',
'uid': 'cc9d527d-b9e4-4635-9161-114875db4af4',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x5',
'y': array([ 0.00523224, 0.00094155, 0.00542564, ..., -0.00702608, -0.00650779,
-0.00691863], shape=(1396,)),
'yaxis': 'y5'},
{'line': {'color': '#19D3F3', 'dash': 'solid'},
'name': 'M22 ',
'type': 'scatter',
'uid': '9fba4b2c-c8bd-4b89-b639-2c634fe992f2',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x6',
'y': array([0.00574, 0.00525, 0.00363, ..., 0.00277, 0.00339, 0.00394],
shape=(1396,)),
'yaxis': 'y6'},
{'line': {'color': '#FF6692', 'dash': 'solid'},
'name': 'M23 ',
'type': 'scatter',
'uid': 'bceccce8-b9e5-468c-99c9-57e9c6607356',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x7',
'y': array([ 0.00364, 0.00427, 0.00207, ..., 0.00457, -0.00234, 0.00653],
shape=(1396,)),
'yaxis': 'y7'},
{'line': {'color': '#B6E880', 'dash': 'solid'},
'name': 'M24 ',
'type': 'scatter',
'uid': 'cc350924-b222-4cad-9e90-85428638f0c3',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x8',
'y': array([-0.01084, 0.00325, -0.01123, ..., 0.00263, -0.00227, 0.00311],
shape=(1396,)),
'yaxis': 'y8'},
{'line': {'color': '#FF97FF', 'dash': 'solid'},
'name': 'M31 ',
'type': 'scatter',
'uid': '20e53864-f7bd-420e-85d9-4ae946377169',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x9',
'y': array([ 0.00278, 0.00634, 0.00219, ..., -0.00055, 0.00105, -0.00037],
shape=(1396,)),
'yaxis': 'y9'},
{'line': {'color': '#FECB52', 'dash': 'solid'},
'name': 'M32 ',
'type': 'scatter',
'uid': 'e904e3d0-8b00-4130-b4be-7f5d5677de18',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x10',
'y': array([ 0.00212, 0.00045, -0.0003 , ..., 0.0018 , 0.00042, -0.00037],
shape=(1396,)),
'yaxis': 'y10'},
{'line': {'color': '#636EFA', 'dash': 'solid'},
'name': 'M33 ',
'type': 'scatter',
'uid': '6a1002f0-8628-4837-8897-6e5b6e859ac3',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x11',
'y': array([ 0.01350493, 0.01769866, 0.01038747, ..., -0.00362567, -0.0041331 ,
-0.00413059], shape=(1396,)),
'yaxis': 'y11'},
{'line': {'color': '#EF553B', 'dash': 'solid'},
'name': 'M34 ',
'type': 'scatter',
'uid': '722faa10-f0fe-45ae-8c6a-bbb7f0ea4eab',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x12',
'y': array([-0.00173427, -0.01084005, -0.00460462, ..., 0.00308251, 0.00368578,
0.00313912], shape=(1396,)),
'yaxis': 'y12'},
{'line': {'color': '#00CC96', 'dash': 'solid'},
'name': 'M41 ',
'type': 'scatter',
'uid': '509ec063-285e-436a-b9ef-5e87b0f2713c',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x13',
'y': array([-0.00986, -0.00917, -0.00712, ..., 0.00585, -0.00882, 0.00692],
shape=(1396,)),
'yaxis': 'y13'},
{'line': {'color': '#AB63FA', 'dash': 'solid'},
'name': 'M42 ',
'type': 'scatter',
'uid': '833fb92a-d21d-4461-878b-94ea91ec646d',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x14',
'y': array([-0.00048, -0.01319, -0.00891, ..., 0.01388, -0.00424, 0.0126 ],
shape=(1396,)),
'yaxis': 'y14'},
{'line': {'color': '#FFA15A', 'dash': 'solid'},
'name': 'M43 ',
'type': 'scatter',
'uid': '53abf639-4471-4c04-87a7-c6ae56c281ed',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x15',
'y': array([ 0.00192427, 0.01533005, 0.00830462, ..., -0.00060251, -0.00090578,
-0.00125912], shape=(1396,)),
'yaxis': 'y15'},
{'line': {'color': '#19D3F3', 'dash': 'solid'},
'name': 'M44 ',
'type': 'scatter',
'uid': '09d05885-c585-4a50-a8e9-8a27353befa5',
'x': array([210.30366, 210.76102, 211.21834, ..., 818.9224 , 819.33886, 819.75528],
shape=(1396,)),
'xaxis': 'x16',
'y': array([ 0.02812493, 0.04063866, 0.03332747, ..., -0.00869567, 0.0075269 ,
-0.00795059], shape=(1396,)),
'yaxis': 'y16'}],
'layout': {'template': '...',
'xaxis': {'anchor': 'y', 'domain': [0.0, 0.2125], 'matches': 'x'},
'xaxis10': {'anchor': 'y10', 'domain': [0.2625, 0.475], 'matches': 'x'},
'xaxis11': {'anchor': 'y11', 'domain': [0.525, 0.7375], 'matches': 'x'},
'xaxis12': {'anchor': 'y12', 'domain': [0.7875, 1.0], 'matches': 'x'},
'xaxis13': {'anchor': 'y13', 'domain': [0.0, 0.2125], 'matches': 'x'},
'xaxis14': {'anchor': 'y14', 'domain': [0.2625, 0.475], 'matches': 'x'},
'xaxis15': {'anchor': 'y15', 'domain': [0.525, 0.7375], 'matches': 'x'},
'xaxis16': {'anchor': 'y16', 'domain': [0.7875, 1.0], 'matches': 'x'},
'xaxis2': {'anchor': 'y2', 'domain': [0.2625, 0.475], 'matches': 'x'},
'xaxis3': {'anchor': 'y3', 'domain': [0.525, 0.7375], 'matches': 'x'},
'xaxis4': {'anchor': 'y4', 'domain': [0.7875, 1.0], 'matches': 'x'},
'xaxis5': {'anchor': 'y5', 'domain': [0.0, 0.2125], 'matches': 'x'},
'xaxis6': {'anchor': 'y6', 'domain': [0.2625, 0.475], 'matches': 'x'},
'xaxis7': {'anchor': 'y7', 'domain': [0.525, 0.7375], 'matches': 'x'},
'xaxis8': {'anchor': 'y8', 'domain': [0.7875, 1.0], 'matches': 'x'},
'xaxis9': {'anchor': 'y9', 'domain': [0.0, 0.2125], 'matches': 'x'},
'yaxis': {'anchor': 'x', 'domain': [0.80625, 1.0]},
'yaxis10': {'anchor': 'x10', 'domain': [0.26875, 0.4625]},
'yaxis11': {'anchor': 'x11', 'domain': [0.26875, 0.4625]},
'yaxis12': {'anchor': 'x12', 'domain': [0.26875, 0.4625]},
'yaxis13': {'anchor': 'x13', 'domain': [0.0, 0.19375]},
'yaxis14': {'anchor': 'x14', 'domain': [0.0, 0.19375]},
'yaxis15': {'anchor': 'x15', 'domain': [0.0, 0.19375]},
'yaxis16': {'anchor': 'x16', 'domain': [0.0, 0.19375]},
'yaxis2': {'anchor': 'x2', 'domain': [0.80625, 1.0]},
'yaxis3': {'anchor': 'x3', 'domain': [0.80625, 1.0]},
'yaxis4': {'anchor': 'x4', 'domain': [0.80625, 1.0]},
'yaxis5': {'anchor': 'x5', 'domain': [0.5375, 0.73125]},
'yaxis6': {'anchor': 'x6', 'domain': [0.5375, 0.73125]},
'yaxis7': {'anchor': 'x7', 'domain': [0.5375, 0.73125]},
'yaxis8': {'anchor': 'x8', 'domain': [0.5375, 0.73125]},
'yaxis9': {'anchor': 'x9', 'domain': [0.26875, 0.4625]}}
})
We may also print the fit statistics.
fit_stats
References
Here you can find the latest jupyter notebook and data files of this example.
Total running time of the script: (0 minutes 2.123 seconds)