How to use ROI to get a right 'good' response
New with you since few days. Coming from Java world, Python is somehow tricky for me !
Here is my problem (question)
I have a sketchpad with 2 named fields ('Diff' and 'Ident') on which the participant clicks depending he have distinguished two identical or different Phonemes (here is the e and the è, in french)
I have an inline script running before "mouse response" to set the correct response (son1 and son2 are the 2 variables containing the name of the ogg files to be heard)
if (var.son1 == var.son2): var.roi_correct_response = "Ident" else: var.roi_correct_response = "Diff"
And then the following inline script after "mouse response"
if var.roi_correct_response == var.cursor_roi: var.correct = var.correct + 1
It gives TypeError: coercing to Unicode: need string or buffer, int found
Any clue ? And another question, is it the right thing to do to calculate the acc value, because I think I should work with correct_response and response, too, shouldn't I ? Or any simpliest solution !
Important remark : there is no feedback inside the loop
Thanks a lot