Python Forum
Unable to import data from Stata-press website - Printable Version

+- Python Forum (https://python-forum.io)
+-- Forum: Python Coding (https://python-forum.io/forum-7.html)
+--- Forum: Data Science (https://python-forum.io/forum-44.html)
+--- Thread: Unable to import data from Stata-press website (/thread-27460.html)



Unable to import data from Stata-press website - Salahaddin - Jun-07-2020

Dear All,

I am new to python. I am trying to replicate code in https://www.statsmodels.org/dev/examples/notebooks/generated/markov_autoregression.htm.

Basically, I run this code:
dta = pd.read_stata('https://www.stata-press.com/data/r14/rgnp.dta').iloc[1:]
But I receive the following error:
"OptionError: "No such keys(s): 'compute.use_numexpr'"

I think it is because the datasets are in a new format compliant with STATA 16. The reason I believe it is because the code works fine with other older datasets. only stata-press website returns an error. Thank you in advance.

Best,
Sam


RE: Unable to import data from Stata-press website - buran - Jun-08-2020

post full traceback in error tags and probably full code that produce the error (minimal reproducible example)

also this code https://www.statsmodels.org/dev/examples/notebooks/generated/markov_autoregression.htm does not work