Skip to content

Commit d3164c4

Browse files
authored
Merge pull request #163 from Remi-Gau/remi-update_doc
[DOC] update doc and jupyter notebook
2 parents f3fdc12 + 6559b92 commit d3164c4

11 files changed

+309
-104
lines changed

.readthedocs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,4 +23,4 @@ formats:
2323
python:
2424
version: 3.7
2525
install:
26-
- requirements: docs/requirements.txt
26+
- requirements: requirements.txt

docs/functions-description.md

Lines changed: 0 additions & 68 deletions
This file was deleted.

docs/installation.md

Lines changed: 14 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -14,19 +14,22 @@
1414

1515
<!-- lint enable -->
1616

17+
## Use the CPP templates for PsychToolBox experiments
18+
19+
The easiest way to use this repository is to create a new repository by using
20+
the
21+
[template PTB experiment repository](https://github.com/cpp-lln-lab/template_PTB_experiment):
22+
this creates a new repository on your github account with all the basic folders,
23+
files and submodules (including CPP_BIDS) already set up. You only have to then
24+
clone the repository and you are good to go.
25+
1726
## Download with git
1827

1928
```bash
2029
cd fullpath_to_directory_where_to_install
2130

22-
# use git to download the code
23-
git clone https://github.com/cpp-lln-lab/CPP_BIDS.git
24-
25-
# move into the folder you have just created
26-
cd CPP_BIDS
27-
28-
# add the src folder to the matlab path and save the path
29-
matlab -nojvm -nosplash -r "addpath(fullfile(pwd, 'src')); savepath ();"
31+
# use git to download the code and the submodules
32+
git clone --recurse-submodules https://github.com/cpp-lln-lab/CPP_BIDS.git
3033
```
3134

3235
Then get the latest commit:
@@ -53,12 +56,6 @@ cd fullpath_to_directory_where_to_install
5356

5457
# use git to download the code
5558
git submodule add https://github.com/cpp-lln-lab/CPP_BIDS.git
56-
57-
# move into the folder you have just created
58-
cd CPP_BIDS
59-
60-
# add the src folder to the matlab path and save the path
61-
matlab -nojvm -nosplash -r "addpath(fullfile(pwd, 'src'))"
6259
```
6360

6461
To get the latest commit you then need to update the submodule with the
@@ -83,7 +80,7 @@ git clone https://github.com/user_name/myExperiment.git
8380
# go into the directory
8481
cd myExperiment
8582

86-
# initialize and get the content of the first level of submodules (e.g. CPP_PTB and CPP_BIDS)
83+
# initialize and get the content of the first level of submodules
8784
git submodule init
8885
git submodule update
8986

@@ -94,6 +91,8 @@ git submodule foreach --recursive 'git submodule update'
9491

9592
## Direct download
9693

94+
NOT RECOMMENDED.
95+
9796
Download the code. Unzip. And add to the matlab path.
9897

9998
Pick a specific version from

docs/source/function_description.rst

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,21 @@ List of functions in the ``src`` folder.
1212
.. autofunction:: createDatasetDescription
1313
.. autofunction:: createFilename
1414
.. autofunction:: createJson
15+
16+
``createJson`` can be used to save in a
17+
human readable format the extra parameters that you used to run your experiment.
18+
This will most likely make the json file non-bids compliant but it can prove useful,
19+
to keep this information in your source dataset
20+
for when you write your methods sections 2 years later after running the experiment.
21+
This ensures that those are the exact parameters you used and you won't have
22+
to read them from the ``setParameters.m`` file and wonder
23+
if those might have been modified when running the experiment
24+
and you did not commit and tagged that change with git.
25+
26+
And for the love of the flying spaghetti monster do not save all your
27+
parameters in a `.mat` file: think of the case when you won't have Matlab or
28+
Octave installed on a computer (plus not everyone uses those).
29+
1530
.. autofunction:: readAndFilterLogfile
1631
.. autofunction:: saveEventsFile
1732
.. autofunction:: userInputs

docs/source/utilities.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,12 @@ List of functions in the ``utils`` folder.
88
.. automodule:: src.utils
99

1010
.. autofunction:: checkCppBidsDependencies
11+
.. autofunction:: checkInput
1112
.. autofunction:: createValidName
1213
.. autofunction:: getFullFilename
1314
.. autofunction:: initializeExtraColumns
1415
.. autofunction:: isPositiveInteger
16+
.. autofunction:: nanPadding
1517
.. autofunction:: printCreditsCppBids
1618
.. autofunction:: removeAllDateSuffix
1719
.. autofunction:: removeDateSuffix

0 commit comments

Comments
 (0)