I am using Psychtoolbox R2020a on MacOS and am using this for loop to display 3 rect frames around my stimuli. However, I cannot get them to display.
% Make a base Rect of 200 by 200 pixels
baseRect = [0 0 300 75];
% Pen width for the frames
penWidthPixels = 6;
% Screen X positions of our three rectangles
squareXpos = [leftX rightX upX];
squareYpos = [leftY rightY upY];
numSquares = 3;
% Make our rectangle coordinates
allRects = nan(4, 3);
for i = 1:numSquares
allRects(:, i) = CenterRectOnPointd(baseRect, squareXpos(i), screenYpos(i));
end
% Display rects to screen
Screen('FrameRect', window, white, allRects, penWidthPixels);