Skip to content

Commit 4f379d8

Browse files
authored
Merge pull request #83 from marcobarilari/marco_update-readme
Improve/Update README file
2 parents 5ac08b9 + 6854071 commit 4f379d8

File tree

4 files changed

+29
-26
lines changed

4 files changed

+29
-26
lines changed

README.md

Lines changed: 23 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -29,21 +29,19 @@
2929

3030
# fMRI localizers for visual motion
3131

32-
## Translational Motion
33-
3432
## Requirements
3533

36-
Make sure that the following toolboxes are installed and added to the matlab / octave path.
34+
Make sure that the following toolboxes are installed and added to the matlab / octave path. See the next section on how to install the submodule toolboxes.
3735

3836
For instructions see the following links:
3937

40-
| Requirements | Used version |
41-
| -------------------------------------------------------- | ------------ |
42-
| [CPP_BIDS](https://github.com/cpp-lln-lab/CPP_BIDS) | ? |
43-
| [CPP_PTB](https://github.com/cpp-lln-lab/CPP_PTB) | ? |
44-
| [PsychToolBox](http://psychtoolbox.org/) | >=3.0.14 |
45-
| [Matlab](https://www.mathworks.com/products/matlab.html) | >=2017 |
46-
| or [octave](https://www.gnu.org/software/octave/) | >=4.? |
38+
| Requirements | Used version |
39+
| --------------------------------------------------------------- | ------------ |
40+
| [CPP_BIDS](https://github.com/cpp-lln-lab/CPP_BIDS) (submodule) | 2.1.0 |
41+
| [CPP_PTB](https://github.com/cpp-lln-lab/CPP_PTB) (submodule) | 1.2.0 |
42+
| [PsychToolBox](http://psychtoolbox.org/) | >=3.0.14 |
43+
| [Matlab](https://www.mathworks.com/products/matlab.html) | >=2017 |
44+
| or [octave](https://www.gnu.org/software/octave/) | >=4.? |
4745

4846
## Installation
4947

@@ -56,11 +54,11 @@ git clone --recurse-submodules https://github.com/cpp-lln-lab/localizer_visual_m
5654

5755
## Structure and function details
5856

59-
### visualLocTranslational
57+
### visualMotionLocalizer
6058

61-
Running this script will show blocks of motion dots (soon also moving gratings) and static dots. Motion blocks will show dots(/gratings) moving in one of four directions (up-, down-, left-, and right-ward)
59+
Running this script will show blocks of motion dots and static dots. Motion blocks will show dots moving in one of four directions (up-, down-, left-, and right-ward) (MT+ localizer) or dots moving inward and outward in the peripheral of the screen (MT/MST localizer).
6260

63-
By default it is run in `Debug mode` meaning that it does not run care about subjID, run n., fMRI triggers, Eye Tracker, etc..
61+
Run in `Debug mode` (see `setParameters.m`) it does not care about subjID, run n., Eye Tracker (soon, at the moment it needs to be set off manually), etc..
6462

6563
Any details of the experiment can be changed in `setParameters.m` (e.g., experiment mode, motion stimuli details, exp. design, etc.)
6664

@@ -85,7 +83,7 @@ Any details of the experiment can be changed in `setParameters.m` (e.g., experim
8583
Set `cfg.pacedByTriggers.do` to `true` and you can then set all the details in this `if` block
8684

8785
```matlab
88-
% Time is here in in terms of number repetition time (i.e MRI volumes)
86+
% Time is here in terms of `repetition time (TR)` (i.e. MRI volumes)
8987
if cfg.pacedByTriggers.do
9088
9189
cfg.pacedByTriggers.quietMode = true;
@@ -107,22 +105,27 @@ end
107105

108106
### subfun/doDotMo
109107

108+
Wrapper function that present the dot stimulation (static or motion) per event.
109+
110110
#### Input
111111

112-
- `cfg`: PTB/machine configurations returned by `setParameters` and `initPTB`
113-
- `expParameters`: parameters returned by `setParameters`
114-
- `logFile`: structure that stores the experiment logfile to be saved
112+
- `cfg`: PTB/machine and experiment configurations returned by `setParameters` and `initPTB`
113+
- `thisEvent`: structure that stores information about the event to present regarding the dots (static or motion, direction, etc.)
114+
- `thisFixation`: structure that stores information about the fixation cross task to present
115+
- `dots`: [...]
116+
- `iEvent`: index of the event of the block at the moment of the presentation
115117

116118
#### Output
117119

118120
- Event `onset`
119121
- Event `duration`
122+
- `dots`: [...]
120123

121-
The dots are drawn on a square that contains the round aperture, then any dots outside of the aperture is turned into a NaN so effectively the actual number of dots on the screen at any given time is not the one that you input but a smaller number (nDots / Area of aperture) on average.
124+
> NB: The dots are drawn on a square that contains the round aperture, then any dots outside of the aperture is turned into a NaN so effectively the actual number of dots on the screen at any given time is not the one that you input but a smaller number (nDots / Area of aperture) on average.
122125
123-
### subfun/expDesign
126+
### subfun/expDesign(MtMst)
124127

125-
Creates the sequence of blocks and the events in them. The conditions are consecutive static and motion blocks (Gives better results than randomised). It can be run as a stand alone without inputs to display a visual example of possible design.
128+
These functions, one per MT+ and one per MT/MST localizer, create the sequence of blocks and the events in them. The conditions are consecutive static and motion blocks (Gives better results than randomised). It can be run as a stand alone with input `cfg` from `setParamenters.m` to display a visual example of possible design.
126129

127130
#### EVENTS
128131

lib/CPP_BIDS

Submodule CPP_BIDS updated 127 files

setParameters.m

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
% VISUAL LOCALIZER
66

7-
% Initialize the parameters and general configuration variables
7+
% Initialize the general configuration variables structure
88
cfg = struct();
99

1010
% by default the data will be stored in an output folder created where the
@@ -15,7 +15,7 @@
1515

1616
%% Debug mode settings
1717

18-
cfg.debug.do = false; % To test the script out of the scanner, skip PTB sync
18+
cfg.debug.do = true; % To test the script out of the scanner, skip PTB sync
1919
cfg.debug.smallWin = false; % To test on a part of the screen, change to 1
2020
cfg.debug.transpWin = false; % To test with trasparent full size screen
2121

@@ -26,7 +26,7 @@
2626
%% Engine parameters
2727

2828
cfg.testingDevice = 'mri';
29-
cfg.eyeTracker.do = true;
29+
cfg.eyeTracker.do = false;
3030
cfg.audio.do = false;
3131

3232
cfg = setMonitor(cfg);

subfun/expDesignMtMst.m

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -90,8 +90,8 @@
9090

9191
cfg.design.blockFixationPosition = [cfg.design.blockFixationPosition; ...
9292
repmat(cfg.design.fixationPosition(2), ...
93-
nbBlocksPerHemifield, ...
94-
1)];
93+
nbBlocksPerHemifield, ...
94+
1)];
9595

9696
end
9797

0 commit comments

Comments
 (0)