tomwalters@0: % demonstration file for 'aim-mat' tomwalters@0: % tomwalters@0: % (c) 2006-2008, University of Cambridge, Medical Research Council tomwalters@0: % Written by Tom Walters (tcw24@cam.ac.uk) tomwalters@0: % http://www.pdn.cam.ac.uk/cnbh/aim2006 tomwalters@0: % $Date: 2008-06-10 18:00:16 +0100 (Tue, 10 Jun 2008) $ tomwalters@0: % $Revision: 585 $ tomwalters@0: tomwalters@0: function plot_sai(input, current_frame_number, current_scale, titlestr) tomwalters@0: %hand_scaling=1; tomwalters@0: tomwalters@0: tomwalters@0: sai=input.data.sai; tomwalters@0: current_frame=sai{current_frame_number}; tomwalters@0: allmax=getallmaxvalue(current_frame); tomwalters@0: str=get_graphics_options(input,input.info.current_sai_module); tomwalters@0: str.extra_options=getfield(input.all_options.sai,input.info.current_sai_module); tomwalters@0: nrchan=getnrchannels(current_frame); tomwalters@0: % if do_single_channel || nrchan==1 tomwalters@0: % current_frame=current_frame; tomwalters@0: % sig=getsinglechannel(current_frame,options.display_single_channel); tomwalters@0: % h=plot(sig,str);set(gca,'YAxisLocation','right'); tomwalters@0: % set(gca,'YLim',[0 allmax*1.1]); tomwalters@0: % else tomwalters@0: hand=plot(current_frame,str); tomwalters@0: %%% TCW - AIM2006 tomwalters@0: %zmin=0;zmax=50/current_scale; tomwalters@0: zmin=0;zmax=(max(current_frame)+eps*1000)/current_scale; tomwalters@0: %%% tomwalters@0: tomwalters@0: %TCW AIM 2006 tomwalters@0: % if hand_scaling == 1 tomwalters@0: set(gca,'Zlim',[zmin,1/current_scale]); tomwalters@0: % else tomwalters@0: % set(gca,'Zlim',[zmin,zmax]); tomwalters@0: % end tomwalters@0: tomwalters@0: %set(gca,'Zlim',[zmin,zmax]); tomwalters@0: %if strcmp(handles.screen_modus,'paper') tomwalters@0: % par=get(hand,'parent'); tomwalters@0: % set(par,'FontSize',12);xlab=get(par,'xlabel');set(xlab,'FontSize',12);ylab=get(par,'ylabel');set(ylab,'FontSize',12); tomwalters@0: %end tomwalters@0: % end tomwalters@0: xlabel('time interval (ms)');ylabel('Frequency (kHz)');title(titlestr);