Home › Forums › Main Forums › Python Forum › customer function for ROC
-
here is the coding I did for ROC curve:
threshold=[*range(100,900,100)]
results=pd.DataFrame()
for x in threshold:
print(x)
roc=Loan.query('CR_Score>x')
roc=roc.assign(subject=i)
roc=roc.groupby('Bad').agg({'Client_ID':'count'})
results=results.append(roc)
resultsthe output is
100#this is only number, no 200 etc
.......
UndefinedVariableError: name 'x' is not defined
can you please tell me what’s wrong with my code? thanks
-
Log in to reply.