Code covered by the BSD License  

Highlights from
MOtion DEcision (MODE) model

image thumbnail
from MOtion DEcision (MODE) model by Massimiliano Versace
MOtion DEcision (MODE) model is a neural model of perceptual decision-making.

Illust7.html

Illust7.m


% Illust7 :: Script that can be run to show the dependence of performance on viewing duration for various coherences in the fixed duration task
%
%% Reference
% Grossberg, S. and Pilly, P. K. (2008). Temporal dyanamics of decision-making during motion perception in the visual cortex. Vision Research, 48(12), 1345-1373.
%
%% Author
% Praveen K. Pilly (advaitp@gmail.com)
%
%% License policy
% Written by Praveen K. Pilly, Department of Cognitive and Neural Systems, Boston University
% Copyright 2009, Trustees of Boston University
%
% Permission to use, copy, modify, distribute, and sell this software and its documentation for any purpose is hereby granted
% without fee, provided that the above copyright notice and this permission notice appear in all copies, derivative works and
% associated documentation, and that neither the name of Boston University nor that of the author(s) be used in advertising or
% publicity pertaining to the distribution or sale of the software without specific, prior written permission. Neither Boston
% University nor its agents make any representations about the suitability of this software for any purpose. It is provided "as
% is" without warranty of any kind, either express or implied. Neither Boston University nor the author indemnify any
% infringement of copyright, patent, trademark, or trade secret resulting from the use, modification, distribution or sale of
% this software.
%
%% Last modified
% June 25, 2009

%%
Tfd=100:20:400; % in msecs (various fixed durations)
% How does accuracy get affected if the experimenter controls viewing
% duration?
tnFD=1+Tfd/(1000*dt); % converting into time-steps

Tfd=round(Tfd); % just to make sure they are positive integers

FDacc=zeros(length(Tfd),6);

for coh=1:cohL
    for trial=1:numtrials
        for tn=1:length(Tfd)
            % The decision is made in favor of the more active LIP cell
            % population at the end of the fixed duration
            if (Y1c(Tfd(tn),trial,coh)>Y2c(Tfd(tn),trial,coh))|(Y1e(Tfd(tn),trial,coh)>Y2e(Tfd(tn),trial,coh))
                FDacc(tn,coh)=FDacc(tn,coh)+1;
            elseif (Y1c(Tfd(tn),trial,coh)==Y2c(Tfd(tn),trial,coh))&(Y1e(Tfd(tn),trial,coh)==Y2e(Tfd(tn),trial,coh))
                if rand>0.5
                    FDacc(tn,coh)=FDacc(tn,coh)+1;
                end
            end
        end
    end
end

FDacc=FDacc*100/numtrials; % calculating the % at each time instant

figure
hold on
for coh=1:cohL
    plot(Tfd,FDacc(:,coh),[colors(coh) 'o--'])
end
hold off
xlabel('Viewing time (msec)','Fontsize',15);
ylabel('Performance (% correct)','Fontsize',15);
axis([0 800 50 100])

Contact us at files@mathworks.com