Notice that the scaling of the temperature domain \(\ \left[\log T_{\min},\log T_{\max}\right]\) to the window [-1, 1] for \(x\) — as described in Eq. \ref{eq:x_scaling}  — is handled automatically by Chebyshev.fit. We do not need to write a function to explicitly calculate \(x\) from \(T\).
The result of the fit is shown in Fig.  \ref{249499}  below.  A Jupyter notebook containing the Python code used to generate this and following figures is attached to Fig.\ref{249499}.  To open it, click on the </> Code button to the left of the figure to open a Jupyter notebook session, then click on R(T)_fit_part_1.ipynb to launch the notebook. The notebook can be run as is (for example, by selecting Restart and Run All from the Kernel menu)  or modified for use with your own data.