You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
| or [octave](https://www.gnu.org/software/octave/)| 4.? |
47
+
| or [Octave](https://www.gnu.org/software/octave/)| 4.? |
51
48
52
-
The exact version required for this to work but it is known to work with:
49
+
Tested:
53
50
- matlab 2015b or octave 4.2.2 and PTB 3.0.14.
54
51
55
-
## 2. <aname='Codeguidestyle'></a>Code guidestyle
52
+
## Documentation
56
53
57
-
We use the `camelCase` to more easily differentiates our functions from the ones from PTB that use a `PascalCase`.
58
-
We use the following regular expression for function names: `[a-z]+(([A-Z]|[0-9]){1}[a-z]+)*`.
54
+
All the documentation is accessible [here](./docs/00_index.md).
59
55
60
-
We keep the McCabe complexity as reported by the [check_my_code function](https://github.com/Remi-Gau/check_my_code) below 15.
56
+
## Content
61
57
62
-
We use the [MISS_HIT linter](https://florianschanda.github.io/miss_hit/style_checker.html) to automatically fix some linting issues. The code style and quality is also checked during the continuous integration.
58
+
```bash
59
+
├── demos # quick demo of how to use some functions
60
+
├── dev # templates for experiment (will be moved out soon)
61
+
├── docs # documentation
62
+
├── manualTests # all the tests that cannot be automated (yet)
63
+
├── src # actual code of the CPP_PTB
64
+
│ ├── aperture # function related to create apertur (circle, wedge, bar...)
65
+
│ ├── dot # functions to simplify the creations of RDK
66
+
│ ├── errors # all error functions
67
+
│ ├── fixation # to create fixation cross, dots
68
+
│ ├── keyboard # to collect responses, abort experiment...
69
+
│ ├── randomization # functions to help with trial randomization
70
+
│ └── utils # set of general functions
71
+
└── tests # all the tests that that can be run by github actions
72
+
```
63
73
64
-
## 3. <aname='Howtoinstall'></a>How to install
74
+
## How to install
65
75
66
-
### 3.1. <aname='Downloadwithgit'></a>Download with git
Remember that updates to submodules need to be committed as well.
111
115
112
-
#### 3.2.1. <aname='Exampleforsubmoduleusage'></a>Example for submodule usage
116
+
#### Example for submodule usage
113
117
114
118
So say you want to clone a repo that has some nested submodules, then you would type this to get the content of all the submodules at once (here with my experiment repo):
Also note that this might not work at all if you have not set a command line alias to start Matlab from a terminal window by just typing `matlab`. :wink:
We keep the McCabe complexity below 15 as reported by the [check_my_code function](https://github.com/Remi-Gau/check_my_code) or the [MISS_HIT code checker](https://florianschanda.github.io/miss_hit). A couple of code quality metrics are also checked automatically by MISS_HIT (avoiding functions with too many nested `if` blocks).
240
177
241
-
This script is a stand-alone function that can be useful as a sandbox to develop the PTB audio/visual stimulation of your experiment. No input/output required.
178
+
We use the [MISS_HIT linter](https://florianschanda.github.io/miss_hit/style_checker.html) to automatically fix some linting issues.
242
179
243
-
Here, a tutorial from https://peterscarfe.com/contrastgratingdemo.html is provided for illustrative purpose (notice that some variable names are updated to our code style). For your use, you will delete that part.
180
+
The code style and quality is also checked during the [continuous integration](./.travis.yml).
244
181
245
-
It is composed of two parts:
246
-
- a fixed structure that will initialize and close PTB in 'debug mode'
- the actual sandbox where to set your dynamic variables (the stimulation
249
-
parameters) and the 'playground' where to develop the stimulation code
182
+
## Unit tests
250
183
251
-
When you are happy with it, ideally you will move the vars in `setParameters.m` and the stimulation code in a separate function in `my-experiment-folder/subfun`. The code style and variable names are the same used in `cpp-lln-lab/CPP_PTB`github repo, therefore it should be easy to move everything in your experiment scripts (see the template that is annexed in `cpp-lln-lab/CPP_PTB`).
184
+
Unit tests are run with the mox unit toolbox and automated with github action on Octave.
252
185
253
-
## 7. <aname='Contributors'></a>Contributors ✨
186
+
## Contributors ✨
254
187
255
188
Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/docs/en/emoji-key)):
0 commit comments