Commit 9088e6fd authored by Jesse Heckman's avatar Jesse Heckman

LSL correct

parent 6afa7dba
......@@ -2,6 +2,6 @@
% these lines will add the PBToolbox functions to your userpath
% and initialize your matlab during startup.
pbpath = '/Users/jjheckman/Documents/Code/Gitlab/pbtoolbox';
pbpath = [PBPATH]
addpath(genpath(pbpath));
pb_initialize;
\ No newline at end of file
......@@ -16,7 +16,7 @@ function pb_initializetoolbox()
clc; disp('Initializing ProgrammeerBeerToolbox...');
pbpath = strrep(which('pb_initializetoolbox.m'),'pb_initializetoolbox.m','');
text = fileread([pbpath 'documentation/templates/template_startup.txt']);
text = fileread([pbpath 'documentation' filesep 'templates' filesep 'template_startup.txt']);
disp([newline ' - localising startup.m']);
if isempty(fstartup)
......
......@@ -19,7 +19,7 @@ function [ses,str] = pb_runLSL(varargin)
'type=''Pupil Capture @ pupil-desktop'' and name=''Pupil Python Representation - Eye 0''', ...
'type=''Pupil Capture @ pupil-desktop'' and name=''Gaze Python Representation''', ...
'type=''Pupil Capture @ pupil-desktop'' and name=''Pupil Primitive Data - Eye 0''', ...
'type=''OptiTrack Mocap @ DCN-VS03'' and name=''Rigid Bodies'''};
'type=''OptiTrack Mocap @ DCN-OT01'' and name=''Rigid Bodies'''};
if de; tmp(end+1) = streams(1); end
if pl; tmp(end+1) = streams(2); end
......
function pb_shadedline(D,varargin)
% PB_SHADEDLINE()
%
% PB_SHADEDLINE() ...
%
% See also ...
% PBToolbox (2018): JJH: j.heckman@donders.ru.nl
fig = pb_keyval('fig',varargin,gcf);
ax = pb_keyval('axis',varargin,gca);
col = pb_keyval('col',varargin);
alpha = pb_keyval('alpha',varargin,.3);
smooth = pb_keyval('smooth',varargin,1);
figure(fig);
axes(ax);
hs = ~ishold;
hold on;
F = 1 : size(D,2);
if ne(size(F,1),1)
F=F';
end
amean=smooth(nanmean(D),smth)';
astd=nanstd(D); % to get std shading
% astd=nanstd(amatrix)/sqrt(size(amatrix,1)); % to get sem shading
if exist('alpha','var')==0 || isempty(alpha)
fill([F fliplr(F)],[amean+astd fliplr(amean-astd)],acolor,'linestyle','none');
acolor='k';
else
fill([F fliplr(F)],[amean+astd fliplr(amean-astd)],acolor, 'FaceAlpha', alpha,'linestyle','none');
end
plot(F,amean,acolor,'linewidth',1.5); %% change color or linewidth to adjust mean line
if hs; hold off; end
end
% % % % % % % % % % % % % % % % % % % % % % % % % % % % % % %
% %
% Part of Programmeer Beer Toolbox (PBToolbox) %
% Written by: Jesse J. Heckman (2018) %
% %
% % % % % % % % % % % % % % % % % % % % % % % % % % % % % % %
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment