From c1506b35ce7591acc212c44ed4576fe83e4dc820 Mon Sep 17 00:00:00 2001 From: Yaroslav Halchenko Date: Thu, 8 Oct 2020 17:06:46 -0400 Subject: [PATCH 1/4] BF: make TAB-like-separate TSV example use tabs MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Original example in .md looks like tab separated since its rendition is ugly, but it is just that -- spaces were not used, not tabs. Just so it might come handy (may be there is a command for that) to display spaces and tabs for content in clipboard you could use smth like $> xsel -o | sed -e 's, ,·,g' -e 's,\t,⇰,g' onset·duration⇰response_time⇰correct⇰stop_trial⇰go_trial 200⇰200⇰0⇰n/a⇰n/a⇰n/a% --- src/02-common-principles.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/02-common-principles.md b/src/02-common-principles.md index 7888bd7fd9..387f9a1b32 100644 --- a/src/02-common-principles.md +++ b/src/02-common-principles.md @@ -446,8 +446,8 @@ exponent. TSV files MUST be in UTF-8 encoding. Example: ```Text -onset duration response_time correct stop_trial go_trial -200 200 0 n/a n/a n/a +onset duration response_time correct stop_trial go_trial +200 200 0 n/a n/a n/a ``` Tabular files MAY be optionally accompanied by a simple data dictionary From 1cae338ba61ca4aed1d10ac98f3c86d9d54d9d2e Mon Sep 17 00:00:00 2001 From: Yaroslav Halchenko Date: Thu, 8 Oct 2020 17:15:22 -0400 Subject: [PATCH 2/4] ENH: add a note about tabs replaced with spaces in examples/html/pdf More work needs to be done to make it all uniform and factually correct. In "theory" markdown sources should use tabs. HTML (and PDF) rendering should provide nice rendition of those while layouting into a proper tabular presentation and using some unicode characters to depict tab symbols. For now -- note should suffice --- src/02-common-principles.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/02-common-principles.md b/src/02-common-principles.md index 387f9a1b32..55e92aa963 100644 --- a/src/02-common-principles.md +++ b/src/02-common-principles.md @@ -450,6 +450,10 @@ onset duration response_time correct stop_trial go_trial 200 200 0 n/a n/a n/a ``` +**Note**: TSV examples in the document can be re-formatted using +spaces instead of tabs for human readability, and have tabs replaced +with spaces by used for rendering HTML or PDF. + Tabular files MAY be optionally accompanied by a simple data dictionary in the form of a JSON [object](https://www.json.org/json-en.html) within a JSON file. From 985cc8a75fd868b8364e69842071688557ff57d8 Mon Sep 17 00:00:00 2001 From: Yaroslav Halchenko Date: Thu, 29 Oct 2020 10:32:47 -0700 Subject: [PATCH 3/4] Improve note on spaces being used in this document Co-authored-by: Stefan Appelhoff --- src/02-common-principles.md | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/02-common-principles.md b/src/02-common-principles.md index 55e92aa963..2c4e6c12ec 100644 --- a/src/02-common-principles.md +++ b/src/02-common-principles.md @@ -450,10 +450,11 @@ onset duration response_time correct stop_trial go_trial 200 200 0 n/a n/a n/a ``` -**Note**: TSV examples in the document can be re-formatted using -spaces instead of tabs for human readability, and have tabs replaced -with spaces by used for rendering HTML or PDF. - +**Note**: The TSV examples in this document (like the one above this note) +are occasionally formatted using space characters instead of tabs to improve +human readability. +Directly copying and then pasting these examples from the specification +for use in new BIDS datasets can lead to errors and is discouraged. Tabular files MAY be optionally accompanied by a simple data dictionary in the form of a JSON [object](https://www.json.org/json-en.html) within a JSON file. From 593d78f8b9a7655a96d13ad7af086a99e90ff6f2 Mon Sep 17 00:00:00 2001 From: Stefan Appelhoff Date: Thu, 29 Oct 2020 18:37:39 +0100 Subject: [PATCH 4/4] add line break --- src/02-common-principles.md | 1 + 1 file changed, 1 insertion(+) diff --git a/src/02-common-principles.md b/src/02-common-principles.md index 2c4e6c12ec..0124288134 100644 --- a/src/02-common-principles.md +++ b/src/02-common-principles.md @@ -455,6 +455,7 @@ are occasionally formatted using space characters instead of tabs to improve human readability. Directly copying and then pasting these examples from the specification for use in new BIDS datasets can lead to errors and is discouraged. + Tabular files MAY be optionally accompanied by a simple data dictionary in the form of a JSON [object](https://www.json.org/json-en.html) within a JSON file.