You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This could be an issue with statsmodels rather than Plotly, but when trying to fit trendlines to a line which only contains one repeated point, only one parameter is returned from the statsmdels fit and an error occurs when trying to build the hover header for the trendline.
Traceback (most recent call last):
File "C:\Users\slishak\AppData\Local\Programs\Python\Python38\lib\site-packages\IPython\core\interactiveshell.py", line 3331, in run_code
exec(code_obj, self.user_global_ns, self.user_ns)
File "<ipython-input-17-ef61e6ef2734>", line 1, in <module>
fig = px.scatter(df, x='y', y='x', trendline='ols')
File "C:\Users\slishak\AppData\Local\Programs\Python\Python38\lib\site-packages\plotly\express\_chart_types.py", line 62, in scatter
return make_figure(args=locals(), constructor=go.Scatter)
File "C:\Users\slishak\AppData\Local\Programs\Python\Python38\lib\site-packages\plotly\express\_core.py", line 1907, in make_figure
patch, fit_results = make_trace_kwargs(
File "C:\Users\slishak\AppData\Local\Programs\Python\Python38\lib\site-packages\plotly\express\_core.py", line 298, in make_trace_kwargs
fit_results.params[1],
IndexError: index 1 is out of bounds for axis 0 with size 1
Versions:
plotly==4.8.0
statsmodels==0.11.1
The text was updated successfully, but these errors were encountered:
This could be an issue with statsmodels rather than Plotly, but when trying to fit trendlines to a line which only contains one repeated point, only one parameter is returned from the statsmdels fit and an error occurs when trying to build the hover header for the trendline.
Versions:
The text was updated successfully, but these errors were encountered: