In the below graph there are 4 series of points. These points are symmetric respect to $OX$ axis and also with the $OY$ axis.
I have to create/to draw two parallel lines in order to include all these points in between. Then, the distance between these two lines will be the error which I need to compute.
My idea:
Find out the highest point for each position on $OX$ axis.
Find out the highest point from step 1.
Compute the slope from the point found at step 2 to the points from step 1.
Find out the minimum slope
We have 2 points: $A1(x_{1}, y_{1})$ and $B1(x_{2}, y_{2})$ marked with blue circle on my picture. Having these 2 points and knowing that the points are symmetric we can conclude also that the second line, parallel with the first one will pass through $A2(-x_{1}, -y_{1})$ and $B2(-x_{2},-y_{2})$ marked with red.
Now, it can be computed the distance between these 2 lines
BUT there is also another idea better than mine, I suppose.
I compute this error using only 4 points, but every point on the graph has its own weight and importance. So, I am thinking somehow to take into consideration all these points. Maybe it is an optimization/minimization problem.

$\color{brown}{\textbf{The task standing.}}$
Let there be $\;n\;$ series of points in which the points of each series have the same abscissas and different ordinates. It is required to find a pair of parallel straight lines with the minimum possible distance along the ordinate, between which the points of all series are located.
The given data can be represented in the form of the vectors
Proposed algorithm consists of the next steps:
$\color{brown}{\textbf{Calculation of the convex hull.}}$
The given vectors $\;x_i, y_i,z_i\;$ allow to define the lower and upper polylines of the given set of points, wherein concave part of these polylines does not influence to the final result. Elimination of the inner vertice from the given table holds the convex hull of the given set of points.
The convex hull vertice $L_k=(\overline x_k,\overline y_k),\;(k=1,2,\dots\overline m)\;$ can be obtained by the next algorithm:
I.e. $\;L\;$ is the chain of vertice $\;(x_i,y_i)\;$, where each next vertex provides the lowest slope with the previous one.
The convex hull vertice $H_k=(\hat x_k,\hat y_k),\;(k=1,2,\dots,\hat m)\;$ can be obtained by the next algorithm:
I.e. $\;H\;$ is the chain of vertice $\;(x_i,z_i)\;$, where each next vertex provides the highest slope with the previous one.
For example, the data of the table $(1)$ \begin{vmatrix} i & 1 & 2 & 3 & 4 & 5 & 6 & 7 & 8 & 9 \\ x_i & -7.0 & -6.2 & -4.2 & -2.9 & 0.0 & 2.9 & 4.2 & 6.2 & 7.0 \\ y_i & -4.5 & -3.8 & -3.6 & -2.8 & -1.8 & 1.0 & 0.8 & 1.6 & 2.2 \\ z_i & -2.2 & -1.6 & -0.8 & -1.0 & 1.8 & 2.8 & 3.6 & 3.8 & 4.5\tag1 \end{vmatrix}
can be presented via the vertices of the convex hull in the form of
$$L = \left(\dbinom{-7.0}{-4.5},\dbinom{-4.2}{-3.6},\dbinom{0.0}{-1.8},\dbinom{6.2}{1.6},\dbinom{7.0}{2.2}\right),\tag2$$
$$H = \left(\dbinom{-7.0}{-2.2},\dbinom{-6.2}{-1.6},\dbinom{0.0}{1.8},\dbinom{4.2}{3.6},\dbinom{7.0}{4.5}\right).\tag3$$
Also, the convex hull can be obtained graphically.
$\color{brown}{\textbf{Detalization of the optimization task.}}$
The obtained convex hull can be presented in the form of $$y(x)\in[y^\,_L(x),y^\,_H(x)],\tag4$$
where $$y^\,_L(x) = \overline y_k + \overline s_k(x-\overline x_k),\;\text{if}\; x\in[\overline x_k,\overline x_{k+1}];\qquad \overline s_k = \dfrac{\overline y_{k+1}-\overline y_k}{\overline x_{k+1}-\overline x_k};\tag5$$
$$y^\,_H(x) = \hat y_k + \hat s_k(x-\hat x_k),\;\text{if}\; x\in[\hat x_k,\hat x_{k+1}];\qquad \hat s_k = \dfrac{\hat y_{k+1}-\hat y_k}{\hat x_{k+1}-\hat x_k}.\tag6$$
Let $\;s\;$ is the slope of the required parallel lines. Then the equation of the lower line is $$Y_L(s,x) = \overline y^\,_{l(s)} + s(x-\overline x_{l(s)}),\tag7$$ where $$l(s) = \begin{cases} 1,\;\text{if}\;s\in(-\infty,\overline s_1]\\ k+1,\;\text{if}\;s\in[\overline s_k,\overline s_{k+1}]\\ \overline m,\;\text{if}\;s\in[\overline s_m,\infty)\\ \end{cases}\tag{7a}$$ is the number of the lower boundary vertex.
The equation of the higher line is $$Y_H(s,x) = \hat y^\,_{h(s)} + s(x-\hat x_{h(s)}),\tag8$$ where $$h(s) = \begin{cases} \hat m,\;\text{if}\;s\in(-\infty,\hat s_m]\\ k+1,\;\text{if}\;s\in[\hat s_{k+1},\hat s_k]\\ 1,\;\text{if}\;s\in[\hat s_1,\infty)\\ \end{cases}\tag{8a}$$ is the number of the higher boundary vertex.
In the previous example, from $(2),(7a)$ should $$ l(s) = \begin{cases} 1,\;\text{if}\;s\in(-\infty,\frac9{28}]\\ 2,\;\text{if}\;s\in[\frac9{28},\frac37]\\ 3,\;\text{if}\;s\in[\frac37,\frac{17}{31}]\\ 4,\;\text{if}\;s\in[\frac{17}{31},\frac34]\\ 5,\;\text{if}\;s\in[\frac34,\infty) \end{cases}\Rightarrow Y_L(s,x) = \begin{cases} -4.5+s(x+7.0),\;\text{if}\;s\in(-\infty,\frac9{28}]\\ -3.6+s(x+6.2),\;\text{if}\;s\in[\frac9{28},\frac37]\\ -1.8+sx,\;\text{if}\;s\in[\frac37,\frac{17}{31}]\\ 1.6+s(x-6.2),\;\text{if}\;s\in[\frac{17}{31},\frac34]\\ 2.2+s(x-7.0),\;\text{if}\;s\in[\frac34,\infty). \end{cases} $$
From $(3),(8a)$ should $$h(s) = \begin{cases} 5,\;\text{if}\;s\in(-\infty,\frac9{28}]\\ 4,\;\text{if}\;s\in[\frac9{28},\frac37]\\ 3,\;\text{if}\;s\in[\frac37,\frac{17}{31}]\\ 2,\;\text{if}\;s\in[\frac{17}{31},\frac34]\\ 1,\;\text{if}\;s\in[\frac34,\infty)\\ \end{cases}\Rightarrow Y_H(s,x) = \begin{cases} 4.5+s(x-7.0),\;\text{if}\;s\in(-\infty,\frac9{28}]\\ 3.6+s(x-4.2),\;\text{if}\;s\in[\frac9{28},\frac37]\\ 1.8+sx,\;\text{if}\;s\in[\frac37,\frac{17}{31}]\\ -1.6+s(x+6.2),\;\text{if}\;s\in[\frac{17}{31},\frac34]\\ -2.2+s(x+7.0),\;\text{if}\;s\in[\frac34,\infty). \end{cases} $$
And the distance between the boundary parallel lines with the given slope $\;s\;$ equals to
$$D(s) = Y_H(s,x) - Y_L(s,x) = \begin{cases} 9.0-14.0s,\;\text{if}\;s\in(-\infty,\frac9{28}]\\ 7.2-8.4s,\;\text{if}\;s\in[\frac9{28},\frac37]\\ 3.6,\;\text{if}\;s\in[\frac37,\frac{17}{31}]\\ -3.2+6.2s,\;\text{if}\;s\in[\frac{17}{31},\frac34]\\ -4.4+14.0s,\;\text{if}\;s\in[\frac34,\infty).\tag9 \end{cases} $$
$\color{brown}{\textbf{Solving of the optimization task.}}$
Detalized optimization task looks simple.
In particular, from $(9)$ should $$\;\min\limits_{\large s\in(-\infty,\frac9{28}]} D(s) = 9-14\cdot\frac 9{28} = 4.5,$$ $$\;\min\limits_{\large s\in[\frac9{28},\frac37]} D(s) = 7.2-8.4\cdot\frac 37 = 3.6,$$ $$\;\min\limits_{\large s\in[\frac37,\frac{17}{31}]} D(s) = 3.6,$$ $$\;\min\limits_{\large s\in[\frac{17}{31},\frac34]} D(s) = -3.2+6.2\cdot\frac 17{31} = 3.6,$$ $$\;\min\limits_{\large s\in[\frac34,\infty)} D(s) = -4.4+14.0\cdot\frac 34 = 6.1,$$ and $$\mathbf{\min D(s) = 3.6 \;\text{at}\; s\in\left[\frac37,\frac{17}{31}\right]},$$ $$Y_L(s,x) = 1.8-sx,\quad Y_L(s,x) = 1.8+sx.$$