klabhub / neurostim

Design and run visual neuroscience experiments using Matlab and the Psychophysics Toolbox.
MIT License
5 stars 4 forks source link

Behavioral requirements that go to Inf time never satisfied. #39

Closed adammorrissirrommada closed 7 years ago

adammorrissirrommada commented 8 years ago

Often we say "fixate until the end of the trial" by setting the "to" time to Inf or '@cic.trialDuration'. But these cases are currently never satisfied because it doesn't check the behavior once the trial ends. At the end of the trial, time==Inf should be considered equal to cic.trialDuration and behaviors should be checked once last time.

adammorrissirrommada commented 7 years ago

I think there is no easy way to solve this for Inf values. Feedback items, for example, are delivered based on their criterion function, which often compares a "to" time of Inf to trial time. That will never return true.

I think this is less of an issue now that function properties are done more efficiently. People can set a behavior "to" to '@cic.trialDuration' if that's what they want. I tried that with behaviorDemo f1 and a sound feedback item and it worked.