From d6e5f4b3a78c63d8734a5ea0606177a8df54531c Mon Sep 17 00:00:00 2001 From: Cian Monnin Date: Fri, 9 Aug 2024 10:09:02 -0400 Subject: [PATCH] fix: docs --- docs/source/{home.rst => index.rst} | 8 ++++---- docs/source/usage.rst | 14 ++++++-------- 2 files changed, 10 insertions(+), 12 deletions(-) rename docs/source/{home.rst => index.rst} (94%) diff --git a/docs/source/home.rst b/docs/source/index.rst similarity index 94% rename from docs/source/home.rst rename to docs/source/index.rst index df2a465..07f83fb 100644 --- a/docs/source/home.rst +++ b/docs/source/index.rst @@ -1,5 +1,5 @@ Welcome to PictureNamingTask's documentation! -=================================== +============================================== **PictureNamingTask** This is task is a modernized version of a classic neuropsychological task known as a "picture naming task", where an individual is presented with a set of pictures of sheet of paper and asked to name each of them (The "Boston Naming Test"[1] being the most frequently used). The classic task is "fixed" in terms of the number of images and which images are shown. Classically, the number correct and the answer provided are recorded as a measurement. This expands on the classic version by allowing a user to add and remove stimuli as they deem necessary. Each stimulus also has a difficulty level associated with it. This allows for dynamic advancement and regression according to schedule set by the task administrator. @@ -23,8 +23,8 @@ Contents -------- .. toctree:: - - home - usage + + index + usage diff --git a/docs/source/usage.rst b/docs/source/usage.rst index 44ad8e6..e43b741 100644 --- a/docs/source/usage.rst +++ b/docs/source/usage.rst @@ -4,14 +4,13 @@ Usage .. _installation: Serving locally ------------- +---------------- To use PictureNamingTask locally a simple http server can be used. Either download the dist from the github or build the package from source eg ``npm build`` Then the index.html file can be served locally. Python3 offers a command to serve the index.html locally with one command. First ensure python3 is installed. `It can be found here `_. Choose the appropriate package for the OS that you have. Using a terminal or powershell first navitage to the directory containing the index.html file then: .. code-block:: console - cd path/to/directory/containing/index.html python -m http.server @@ -32,7 +31,7 @@ To start the server on another port use (example 8080): More information about ``python http.server`` can be found here https://docs.python.org/3/library/http.server.html -.. _adding-stimuli +.. _adding-stimuli: Adding stimuli ---------------- @@ -47,10 +46,10 @@ Stimuli are added to the data.csv found in the `dist/assets` directory as follow "path/to/img_of_a_dog.jpg", "1", "Un chien", "fr" "path/to/img_of_a_cat.jpg", "2", "Un chat", "fr" -.. _changing-experiment-settings +.. _changing-experiment-settings: Changing experiment settings ----------------- +---------------------------- Experiment settings are changed in the experimentSettings.csv file which is located in the `dist/assets` directory. A template for this file can be found in the `public` directory: `public/experimentSettings ` These settings are described below: @@ -67,10 +66,10 @@ These settings are described below: :header: totalNumberOfTrialsToRun, advancementSchedule, regressionSchedule, language, seed, initialDifficulty, numberOfLevels, 5, 2, 0, en, 42, 1, 9 -.. _adding-additional-languge +.. _adding-additional-languge: Adding additional language ------------- +-------------------------- Adding additional languages can be accomplished by accessing the `locales` directory in `dist/assets` and adding a `translation.json` for the language of interest. `translation.json` must be placed in a `locales/XX/` directory where `XX` is the two letter language code for the language of interest. @@ -79,4 +78,3 @@ Images with the corresponding language code must be included in the `data.csv` a -