Closed HebaSobhi2019 closed 4 years ago
Hi @HebaSobhi2019 ,
Thanks for reaching out. However, the info you provided is not related to SDK, it might be python syntax problem. If you are using ASK python SDK and find problems while using our package, you could ask question here.
Thanks, Shen
Hey @HebaSobhi2019 , this is a python related issue and unrelated to the SDK.
Statements inside the for
loop needs to be indented for Python to recognize the structure to execute. More information here.
from statsmodels.stats.stattools import durbin_watson
out = durbin_watson(model_fitted.resid)
for col, val in zip(df.columns, out):
print(adjust(col), ':', round(val, 2))
Please feel to reopen in case you face issues with the ask-sdk*
libraries we offer. Also, since this is the NodeJS repo, I would suggest you to create issues on the Python repo since you are using Python.
Python language is a very sensitive language for indentation, it has caused confusion for many beginners. Putting in an extra space or leaving one out where it is needed will surely generate an error message . Some common causes of this error include:
The error message IndentationError: expected an indented block would seem to indicate that you have an indentation error. It is probably caused by a mix of tabs and spaces. The indentation can be any consistent white space . It is recommended to use 4 spaces for indentation in Python, tabulation or a different number of spaces may work, but it is also known to cause trouble at times. Tabs are a bad idea because they may create different amount if spacing in different editors .
hello every one ,, i need your help i am using Python 3.6 and run then code on it :
from statsmodels.stats.stattools import durbin_watson out = durbin_watson(model_fitted.resid)
for col, val in zip(df.columns, out): print(adjust(col), ':', round(val, 2))
then i get this error : File "", line 6
for col, val in zip(df.columns, out):
^
IndentationError: expected an indented block