The result of a certain Python (statsmodel module) code in org-mode is abbreviated:
#+BEGIN_SRC python
import pandas as pd
import statsmodels.api as sm
auto_df=pd.read_csv('Auto.csv', usecols= ['mpg', 'horsepower'], na_values= ['?'])
auto_df['horsepower'] = pd.to_numeric(auto_df['horsepower'])
auto_df.dropna(inplace=True)
X = auto_df['horsepower']
X = sm.add_constant(X)
olsmod = sm.OLS(auto_df['mpg'], X)
olsres = olsmod.fit()
pred = olsres.get_prediction([1,98])
return(pred.summary_frame())
#+END_SRC
#+RESULTS:
: mean mean_se ... obs_ci_lower obs_ci_upper
: 0 24.467077 0.251262 ... 14.809396 34.124758
:
: [1 rows x 6 columns]
I'm referring to the ellipses in the table below #+Results
.
How can I see the full results table?
A comment suggested this could be a a pandas issue, but I don't think so since the output is from a statsmodels function.
And I don't think it's because of statsmodels because here, the full is pred.summary_frame()
results table is shown:
#+BEGIN_SRC python
import pandas as pd
import statsmodels.api as sm
import numpy as np
nsample = 50
sig = 0.25
X = np.linspace(0, 20, nsample)
X = sm.add_constant(X)
beta = [5., 0.5]
y_true = np.dot(X, beta)
y = y_true + sig * np.random.normal(size=nsample)
olsmod = sm.OLS(y, X)
olsres = olsmod.fit()
pred = olsres.get_prediction([1,17])
return(pred.summary_frame())
#+END_SRC
#+RESULTS:
: mean mean_se mean_ci_lower mean_ci_upper obs_ci_lower obs_ci_upper
: 0 13.559089 0.0522 13.454134 13.664043 13.069874 14.048303
One more note, the abbreviate one, from my first example, shows fully in the python shell.