Skip to content

Commit b8aab2c

Browse files
committed
change parsing problems
1 parent 4bf8c62 commit b8aab2c

23 files changed

+58
-49
lines changed

src/f_SCR.m

+2-2
Original file line numberDiff line numberDiff line change
@@ -18,14 +18,14 @@
1818
% ● Format
1919
% [fx, dfdx, dfdP] = f_SCR(Xt,Theta,ut,in)
2020
% ● Arguments
21-
% Theta: 4 ER constants (3 ODE params + time)
21+
% * Theta: 4 ER constants (3 ODE params + time)
2222
% 3 SF constants (3 ODE params)
2323
% 3 values per aSCR (invsigma(peaktime), invsigma(std),
2424
% log(amplitude))
2525
% 1 value per eSCR (log(amplitude))
2626
% 2 values per SF (invsigma(peaktime), log(amplitude))
2727
% 2 values per SCL change (invsigma(time), amplitude)
28-
% ut: row 1 - time (after cue onset)
28+
% * ut: row 1 - time (after cue onset)
2929
% row 2 - number of aSCR
3030
% row 3 - number of eSCR
3131
% row 4 - number of SF

src/f_SF.m

+4-4
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@
1313
% ● Format
1414
% [fx, dfdx] = f_SF(Xt,Theta,ut,in)
1515
% ● Arguments
16-
% Theta: 3 general constants
17-
% 2 value per SF (time, log(amplitude))
18-
% ut: row 1 - time (after cue onset)
19-
% row 2 - number of SF
16+
% * Theta: 3 general constants
17+
% 2 value per SF (time, log(amplitude))
18+
% * ut: row 1 - time (after cue onset)
19+
% row 2 - number of SF
2020
% ● History
2121
% Introduced in PsPM 3.0
2222
% Written in 2008-2015 by Dominik R Bach (Wellcome Trust Centre for Neuroimaging)

src/g_SCR.m

+3-1
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,10 @@
11
function [gx,dgdx,dgdPhi] = g_SCR(Xt,Phi,ut,inG)
2-
% ● Description
2+
% ● Description
33
% This is the SCR observation function required by the VBA toolbox. It
44
% adds the three generative processes (phasic SCR, SF, SCL) modelled in
55
% f_SCR.
6+
% ● Format
7+
% [gx,dgdx,dgdPhi] = g_SCR(Xt,Phi,ut,inG)
68
% ● Arguments
79
% Xt: a 7-element vector
810
% Phi: input required by VBA, ignored

src/pspm_align_channels.m

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
% ● Arguments
1010
% * data : [struct] the input data to be processed, in PsPM data format.
1111
% * induration : [double] the duration of the input data.
12-
%Copyright
12+
%History
1313
% Introduced in PsPM 3.1
1414
% Written in 2008-2016 by Dominik R Bach (Wellcome Trust Centre for Neuroimaging)
1515
% Maintained in 2022 by Teddy

src/pspm_bf_FIR.m

+7-7
Original file line numberDiff line numberDiff line change
@@ -17,29 +17,29 @@
1717
%% Check input arguments
1818
if nargin==0
1919
errmsg='No sampling interval stated'; warning('ID:invalid_input', errmsg); return;
20-
end;
20+
end
2121
n = 30;
2222
d = 1;
2323
td = varargin{1}(1);
2424
if nargin == 1 && numel(varargin{1}) > 1
2525
n = varargin{1}(2);
2626
if numel(varargin{1}) >= 3
2727
d = varargin{1}(3);
28-
end;
28+
end
2929

3030
elseif nargin > 1
3131
if nargin >= 2
3232
n = varargin{2}(1);
33-
end;
33+
end
3434
if nargin >= 3
3535
d = varargin{3}(1);
36-
end;
37-
end;
36+
end
37+
end
3838
if td > d
3939
warning('ID:invalid_input', 'Time resolution is larger than duration of the function.'); return;
4040
elseif td == 0
4141
warning('ID:invalid_input', 'Time resolution must be larger than 0.'); return;
42-
end;
42+
end
4343
% initialise FIR
4444
FIR = [zeros(1, n); zeros(round((d*n/td)), n);];
4545
% generate timestamps
@@ -50,5 +50,5 @@
5050
stops=(d*reg)/td;
5151
FIR(starts:stops, reg)=1;
5252
starts=stops+1;
53-
end;
53+
end
5454
return

src/pspm_check_model.m

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
function [model, options] = pspm_check_model(model, options, modeltype)
2-
%Definition
2+
%Description
33
% pspm_check_model automatically determine the fields of the struct model
44
% for the corresponding function. It also checks the options structure
55
% and uses it to determine whether overwriting of the model file is

src/pspm_denoise_spike.m

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
% * header : header of data
99
% * kbdata : keyboard channel data
1010
% * cutoff : the cut off value for denoising
11-
%Arguments
11+
%Outputs
1212
% * data: denoised data
1313
% ● History
1414
% Introduced in PsPM 3.0

src/pspm_emg_pp.m

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
% be added or the previous outputs of this function should
2727
% be replaced. (Default: 'replace')
2828
% ● Outputs
29-
% channel_index: index of channel containing the processed data
29+
% * channel_index: index of channel containing the processed data
3030
% ● References
3131
% [1] Khemka S, Tzovara A, Gerster S, Quednow BB, Bach DR (2017).
3232
% Modelling startle eye blink electromyogram to assess fear learning.

src/pspm_find_eye.m

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
function [sts, eye, new_chantype] = pspm_find_eye(chantype)
2-
%Definition
2+
%Description
33
% pspm_get_eye detects the eye location ('l', 'r', 'c', '') from an
44
% eyetracker channel type
55
% ● Format

src/pspm_get_biograph.m

+2-2
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@
1414
% ├──────.data : The data read from the file.
1515
% └────.marker : The type of marker, such as 'continuous'
1616
% ● Outputs
17-
% import : The import struct that saves importing information
18-
% sourceinfo : The struct that saves information of original data source
17+
% * import : The import struct that saves importing information
18+
% * sourceinfo : The struct that saves information of original data source
1919
% ● History
2020
% Introduced in PsPM 3.0
2121
% Written in 2008-2015 Dominik R Bach (Wellcome Trust Centre for Neuroimaging)

src/pspm_get_biotrace.m

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
% ├──────.data : The data read from the file.
1313
% └────.marker : The type of marker, such as 'continuous'
1414
% ● Outputs
15-
% import : The import struct that saves importing information
16-
% sourceinfo : The struct that saves information of original data source
15+
% * import : The import struct that saves importing information
16+
% * sourceinfo : The struct that saves information of original data source
1717
% ● History
1818
% Introduced in PsPM 3.0
1919
% Written in 2008-2015 by Dominik R Bach (Wellcome Trust Centre for Neuroimaging)

src/pspm_get_markerinfo.m

+6-8
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,7 @@
77
% ● Format
88
% [sts, markerinfo] = pspm_get_markerinfo(filename, options)
99
% ● Arguments
10-
% * filename : [char]
11-
% name of PsPM file
10+
% * filename : [char] name of PsPM file
1211
% if empty, you will be prompted for one
1312
% ┌────options
1413
% ├.marker_chan_num: [int] marker channel number.
@@ -20,12 +19,11 @@
2019
% Define whether to overwrite existing output files or not.
2120
% Default value: determined by pspm_overwrite.
2221
% ● Outputs
23-
% * sts : [double]
24-
% default value: -1 if unsuccessful
25-
% ┌─markerinfo : [struct]
26-
% ├──────.name : [char]
27-
% ├─────.value : ...
28-
% └───.element : ...
22+
% * sts : [double] default value: -1 if unsuccessful.
23+
% ┌────markerinfo
24+
% ├──────.name : [char] marker type name, extracted from the data.
25+
% ├─────.value : [double] marker value, representing event codes or timestamps.
26+
% └───.element : [array]
2927
% ● History
3028
% Introduced in PsPM 6.0
3129
% Written in 2008-2015 by Dominik R Bach (Wellcome Trust Centre for Neuroimaging)

src/pspm_get_smrx.m

+3-3
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@
1414
% ├────.type : [string] The type of input channel, such as 'scr'.
1515
% └──.typeno : [integer] The number of channel type, please see pspm_init.
1616
% ● Outputs
17-
% sts: the status recording whether the function runs successfully.
18-
% import: the struct that stores read information.
19-
% sourceinfo: the struct that stores channel titles.
17+
% * sts: the status recording whether the function runs successfully.
18+
% * import: the struct that stores read information.
19+
% * sourceinfo: the struct that stores channel titles.
2020
% ● Developer
2121
% The following fields are read from the datafile and saved in import
2222
% * data | via CEDS64ReadWaveF/CEDS64ReadEvents/CEDS64ReadMarkers

src/pspm_get_timing.m

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
% [sts, epochs] = pspm_get_timing('missing', epochs, timeunits)
1212
% → For recursive calls also:
1313
% [sts, epochs] = pspm_get_timing('file', filename)
14-
%Arguments
14+
%Argument(s) // need change
1515
% onsets and timeunits are 'seconds', 'samples' or 'markers':
1616
% for defining event onsets for multiple conditions (e. g. GLM)
1717
% intiming is - a multiple condition file name (single session) OR

src/pspm_guide.m

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
% contents{get(hObject,'Value')} returns selected item from the list
1616
% * Hint
1717
% popupmenu controls usually have a white background on Windows.
18-
%Copyright
18+
%History
1919
% Introduced in PsPM 1.0 and terminated in PsPM 6.1.
2020
% Written by Dominik R Bach (Wellcome Centre for Human Neuroimaging) in 2008-2021
2121
% Lastly updated in PsPM 6.1 by Teddy in 2022

src/pspm_help_init.m

+5-3
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,10 @@
11
function out = pspm_help_init
2-
% pspm_help_init sets up the help texts for matlabbatch GUI. This is work
3-
% in progress.
2+
% ● Description
3+
% pspm_help_init sets up the help texts for matlabbatch GUI.
4+
% ● Developer
5+
% This is work in progress.
46

5-
% get functions list
7+
%% get functions list
68
[pth, fname, ext] = fileparts(mfilename('fullpath'));
79

810
filelist = dir(fullfile(pth, '*.m'));

src/pspm_leaky_integrator.m

+3-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
function filtered_data = pspm_leaky_integrator(data, tau)
22
% ● Description
33
% pspm_leaky_integrator applies a leaky integrator filter to the input data
4+
% ● Format
5+
% filtered_data = pspm_leaky_integrator(data, tau)
46
% ● Arguments
57
% * data: A numerical vector representing the input signal to be filtered.
68
% * tau: The time constant of the leaky integrator, representing the
@@ -11,7 +13,7 @@
1113
% * filtered_data: The filtered signal, of the same size as the input data,
1214
% processed by the leaky integrator.
1315

14-
% Initialize the filteredData vector with the same size as input data
16+
%% Initialize the filteredData vector with the same size as input data
1517
filtered_data = zeros(size(data));
1618
% Start with the first value of the input data
1719
filtered_data(1) = data(1);

src/pspm_load_channel.m

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
function [sts, data_struct, infos, pos_of_channel, chantype_sts] = ...
22
pspm_load_channel(fn, channel, channeltype)
3-
%Definition
3+
%Description
44
% pspm_load_channel loads a single data channel and provides integrated
55
% channel checking logic
66
% ● Format

src/pspm_logical2epochs.m

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
% ● History
1414
% Written in 2024 by Bernhard Agoué von Raußendorf
1515

16-
16+
%%
1717
% Compute the differences between consecutive elements in the index array,
1818
% with padding at the start and end
1919
diff_index = diff([0; index(:); 0]);

src/pspm_options.m

+5-3
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
11
function options = pspm_options(options, FunName)
2-
%Definition
2+
%Description
33
% pspm_options automatically determine the fields of options for the
44
% corresponding function.
55
% ● Arguments
6-
% options: a struct to be filled by the function
7-
% FunName: a string, the name of the function where option is used
6+
% * options: a struct to be filled by the function
7+
% * FunName: a string, the name of the function where option is used
8+
% ● Outputs
9+
% * options: a struct containing the options for the specified function.
810
% ● History
911
% Introduced in PsPM 6.1
1012
% Written in 2022 by Teddy

src/pspm_pull_zenodo.m

+1-3
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,7 @@
88
% * datapath: directory where the downloaded files will be stored (string)
99
% ● Outputs
1010
% * sts: status flag
11-
% ● Developer
12-
% dsgd
13-
% edsrgd
11+
1412
fprintf('Pulling data set %i from zenodo.org\n', ID);
1513
mkdir(datapath);
1614

src/pspm_time2index.m

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
% * events : vector of timestamps from a marker channel, will be considered if
1515
% given as input.
1616
% ● Outputs
17-
% index : [integer] index or data point.
17+
% * index : [integer] index or data point.
1818
% ● History
1919
% Introduced in PsPM 5.1.2
2020
% Written in 2021 by Teddy

src/pspm_ui.m

+5
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,15 @@
11
function [hObject, handles] = pspm_ui(hObject,handles,window)
22
% ● Description
33
% pspm_ui controls the UI of the referred handle.
4+
% ● Format
5+
% [hObject, handles] = pspm_ui(hObject,handles,window)
46
% ● Arguments
57
% * hObject : UI controllor of the specific GUI window.
68
% * handles : UI controllor of the specific GUI window.
79
% * window : the name of the specific GUI window.
10+
% ● Outputs
11+
% * hObject : The handle of the main UI figure or control element.
12+
% * handles : A structure containing handles to all UI components.
813
% ● History
914
% Introduced in PsPM 5.1
1015
% Written and maintained in 2021-2022

0 commit comments

Comments
 (0)