mirror of
https://github.com/fjosw/pyerrors.git
synced 2025-03-16 23:30:24 +01:00
Merge branch 'develop' into documentation
This commit is contained in:
commit
28fe7e2dff
1 changed files with 4 additions and 3 deletions
|
@ -635,9 +635,10 @@ def qqplot(x, o_y, func, p):
|
||||||
|
|
||||||
def residual_plot(x, y, func, fit_res):
|
def residual_plot(x, y, func, fit_res):
|
||||||
""" Generates a plot which compares the fit to the data and displays the corresponding residuals"""
|
""" Generates a plot which compares the fit to the data and displays the corresponding residuals"""
|
||||||
xstart = x[0] - 0.5
|
sorted_x = sorted(x)
|
||||||
xstop = x[-1] + 0.5
|
xstart = sorted_x[0] - 0.5 * (sorted_x[1] - sorted_x[0])
|
||||||
x_samples = np.arange(xstart, xstop, 0.01)
|
xstop = sorted_x[-1] + 0.5 * (sorted_x[-1] - sorted_x[-2])
|
||||||
|
x_samples = np.arange(xstart, xstop + 0.01, 0.01)
|
||||||
|
|
||||||
plt.figure(figsize=(8, 8 / 1.618))
|
plt.figure(figsize=(8, 8 / 1.618))
|
||||||
gs = gridspec.GridSpec(2, 1, height_ratios=[3, 1], wspace=0.0, hspace=0.0)
|
gs = gridspec.GridSpec(2, 1, height_ratios=[3, 1], wspace=0.0, hspace=0.0)
|
||||||
|
|
Loading…
Add table
Reference in a new issue