# timing delays in Matlab 5.2 under Mac OS 9.2 ??

**URL:** <https://psychtoolbox.discourse.group/t/timing-delays-in-matlab-5-2-under-mac-os-9-2/951>\
**Category:** Uncategorized\
**Created:** [May 27, 2004, 11:34pm UTC](https://psychtoolbox.discourse.group/t/timing-delays-in-matlab-5-2-under-mac-os-9-2/951 "2004-05-27T23:34:18Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Allen\_Ingling](https://avatars.discourse-cdn.com/v4/letter/a/a183cd/32.png) [@Allen\_Ingling](https://psychtoolbox.discourse.group/u/Allen_Ingling)\
**Post date:** [May 27, 2004, 11:34pm UTC](https://psychtoolbox.discourse.group/t/timing-delays-in-matlab-5-2-under-mac-os-9-2/951/1 "2004-05-27T23:34:18Z")

</div>

Hi,  
  
We had just finished an fmri scanning session, and we noticed   
some time delays in our experiments. Using one experiment   
that we did as an example, the retinotopic mapping, we had a   
wedge of 45 deg, jumping at 45 deg to the next position, and it   
stays at one position in the circle for 4 secs (therefore, it has 8   
positions to bypass before completing one circle).   
  
So, the wedge should take about 32 secs to complete one circle,   
and since we are repeating this 8 times, then the whole   
experiment should take about 256 secs.   
  
However, this is not the case. With the above values, we got   
more than 256 secs overall during a trial run without the fmri. So   
we calibrated our timing to 3.87 secs instead of 4 secs for the   
duration when the wedge stays at one position. It worked fine   
during this fake trial.  
  
However, during the real run and with this new value, we still got   
more than 259 (!!) secs overall, and each circle lasts slightly   
longer than 32 secs. We are using the function 'getsecs' to get   
the timings from the experiment, and no other programs were   
running at the same time.  
  
We are using Matlab 5.2 under Mac OS 9.2 on a G4. I saw on the   
website that there were some bugs found for Matlab 6.5 under   
OSX, but none for Matlab 5 with Mac 9.   
  
I am not sure what is going on, because this program does not   
involve any human response time... we are just trying to get the   
time length of the displaying of the stimulus on screen.   
  
If anyone has any take, suggestion or comment on this issue,   
please do let me know...  
  
Thank you very much!  
  
Tian  
Ophthalmology Research Lab  
University of British Columbia

---

<div class="post-metadata">

**Author:** ![anblick](https://avatars.discourse-cdn.com/v4/letter/a/48db29/32.png) [@anblick](https://psychtoolbox.discourse.group/u/anblick)\
**Post date:** [May 28, 2004, 2:30pm UTC](https://psychtoolbox.discourse.group/t/timing-delays-in-matlab-5-2-under-mac-os-9-2/951/2 "2004-05-28T14:30:04Z")

</div>

It's impossible to diagnose your problem without seeing your code.   
Please post it to the list or send it to me.  
  
keith  
  

> On May 27, 2004, at 7:34 PM, wtianlim2003 wrote:  
>    
> \> Hi,  
> \>  
> \> We had just finished an fmri scanning session, and we noticed  
> \> some time delays in our experiments. Using one experiment  
> \> that we did as an example, the retinotopic mapping, we had a  
> \> wedge of 45 deg, jumping at 45 deg to the next position, and it  
> \> stays at one position in the circle for 4 secs (therefore, it has 8  
> \> positions to bypass before completing one circle).  
> \>  
> \> So, the wedge should take about 32 secs to complete one circle,  
> \> and since we are repeating this 8 times, then the whole  
> \> experiment should take about 256 secs.  
> \>  
> \> However, this is not the case. With the above values, we got  
> \> more than 256 secs overall during a trial run without the fmri. So  
> \> we calibrated our timing to 3.87 secs instead of 4 secs for the  
> \> duration when the wedge stays at one position. It worked fine  
> \> during this fake trial.  
> \>  
> \> However, during the real run and with this new value, we still got  
> \> more than 259 (!!) secs overall, and each circle lasts slightly  
> \> longer than 32 secs. We are using the function 'getsecs' to get  
> \> the timings from the experiment, and no other programs were  
> \> running at the same time.  
> \>  
> \> We are using Matlab 5.2 under Mac OS 9.2 on a G4. I saw on the  
> \> website that there were some bugs found for Matlab 6.5 under  
> \> OSX, but none for Matlab 5 with Mac 9.  
> \>  
> \> I am not sure what is going on, because this program does not  
> \> involve any human response time... we are just trying to get the  
> \> time length of the displaying of the stimulus on screen.  
> \>  
> \> If anyone has any take, suggestion or comment on this issue,  
> \> please do let me know...  
> \>  
> \> Thank you very much!  
> \>  
> \> Tian  
> \> Ophthalmology Research Lab  
> \> University of British Columbia  
> \>  
> \>  
> \>  
> \>  
> \> [http://psychtoolbox.org](http://psychtoolbox.org)  
> \> POST a message to: [psychtoolbox@yahoogroups.com](mailto:psychtoolbox@yahoogroups.com)  
> \> UNSUBSCRIBE by sending a blank message to:  
> \> [psychtoolbox-unsubscribe@yahoogroups.com](mailto:psychtoolbox-unsubscribe@yahoogroups.com)  
> \> Yahoo! Groups Links  
> \>  
> \>  
> \>  
> \>  
> \>  
> \>  
> -----  
> Keith Schneider  
> Department of Psychology  
> Green Hall  
> Princeton University  
> Princeton, NJ 08544  
> (609) 258-1480
