fileformats:hdascii
Unterschiede
Hier werden die Unterschiede zwischen zwei Versionen angezeigt.
Beide Seiten der vorigen RevisionVorhergehende ÜberarbeitungNächste Überarbeitung | Vorhergehende Überarbeitung | ||
fileformats:hdascii [2017/02/28 15:35] – [Double arrays] oliver | fileformats:hdascii [2017/12/22 15:08] (aktuell) – [File extentions and mime types] oliver | ||
---|---|---|---|
Zeile 1: | Zeile 1: | ||
======The HD-ASCII File Format====== | ======The HD-ASCII File Format====== | ||
+ | =====History===== | ||
This component implements the //HD-ASCII File format//, originally designed and implemented by Jan Simon in [[https:// | This component implements the //HD-ASCII File format//, originally designed and implemented by Jan Simon in [[https:// | ||
+ | =====General features===== | ||
The HD-ASCII file format is a container format for any data organized in matrices. The data types are orientated on the types available in the [[https:// | The HD-ASCII file format is a container format for any data organized in matrices. The data types are orientated on the types available in the [[https:// | ||
=====Disadvantages===== | =====Disadvantages===== | ||
- | The HD-ASCII file format is extensivly used in the [[http:// | + | The HD-ASCII file format is extensivly used in the [[http:// |
* The resolution of the numbers is insufficient defineable. This can result in ilusive bugs. | * The resolution of the numbers is insufficient defineable. This can result in ilusive bugs. | ||
Zeile 16: | Zeile 18: | ||
All of these limitations are overruled by the Nimues default open and flexible [[http:// | All of these limitations are overruled by the Nimues default open and flexible [[http:// | ||
- | =====File extentions===== | + | =====File extentions |
To distinguesh different sets of data in the [[http:// | To distinguesh different sets of data in the [[http:// | ||
- | ^ File Extension ^ Frames ^ Description ^ Fix set of variables | | + | ^ File Extension |
- | ^ .glk | single trial | Lower Body Kinetics (PiG) | X | | + | ^ .glk | | single trial | Lower Body Kinetics (PiG) | X | |
- | ^ .glkn | single trial | time normalized .glk | X | | + | ^ .glkn | | single trial | Time normalized .glk-files| X | |
- | ^ .glm | single trial | Lower/Upper Body Kinematics (PiG)| | + | ^ .glm | text/x-glm | single trial | Lower/Upper Body Kinematics (PiG)| X | |
- | ^ .glmn | single trial | time normalized .glm | X | | + | ^ .glmn | | single trial | Time normalized .glm-files |
- | ^ .gle | single trial | EMG data | X | | + | ^ .gle | text/x-gle | single trial | EMG data | X | |
- | ^ .glen | single trial | time normalized .gle | X | | + | ^ .glen | | single trial | Time normalized .gle-files| X | |
- | ^.gla | mean | * lower/upper body kinematics (PiG) | X | | + | ^.gla | text/x-gla | mean| Lower/upper body kinematics (PiG) average files | X | |
- | ^ .pkl | | Meta Data | X | | + | ^ .pkl | | | Meta Data | X | |
- | ^ .glx | single trial | experimentel | + | ^ .glx | text/ |
- | ^ .glxn | single trial | time normalized .glx | | | + | ^ .glxn | | single trial | time normalized .glx | | |
- | ^ .gxa | mean | + | ^ .gxa or .gxa | text/ |
- | ^ .gaf | mean | Foot Kinematics | X | | + | ^ .gaf | text/x-gaf | mean | Foot Kinematics | X | |
- | ^ .glf | + | ^ .glf | | single trial | Foot Kinematics | X | |
- | ^ .glfn | mean | session | + | ^ .glfn |
+ | ^ .gnm | text/x-gnm | | | | | ||
If a single trial is splittet into strides and timenormalized for each stride a seperate file is created. These files are numbered as the following examples shows: | If a single trial is splittet into strides and timenormalized for each stride a seperate file is created. These files are numbered as the following examples shows: | ||
Zeile 68: | Zeile 70: | ||
====String lists (Matlabs cell string)==== | ====String lists (Matlabs cell string)==== | ||
- | The strings of a string list can vary in the length and no trailing spaces are needed. The single strings of the list are written as lines separated by line breaks. Therefore strings must not contain line breaks (ASCII code 10 or 13). For string lists with more than 2 dimensions the first index is varied at first, then the second and so on, so-called | + | The strings of a string list can vary in the length and no trailing spaces are needed. The single strings of the list are written as lines separated by line breaks. Therefore strings must not contain line breaks (ASCII code 10 or 13). For string lists with more than 2 dimensions the first index is varied at first, then the second and so on, so-called columnwise order. |
- | + | ||
- | columnwise order (see examples). | + | |
====Double arrays==== | ====Double arrays==== | ||
Zeile 113: | Zeile 113: | ||
4 5 6 | 4 5 6 | ||
- | =====Multi-dimensional doubles===== | + | ====Multi-dimensional doubles==== |
The approach to use the second dimension as lines and keeping the trailing dimensions together enforces a complex ordering of values. In consequence the array is split at the first dimension in parts. | The approach to use the second dimension as lines and keeping the trailing dimensions together enforces a complex ordering of values. In consequence the array is split at the first dimension in parts. | ||
Zeile 153: | Zeile 153: | ||
of all other dimensions 2*4 = 8. | of all other dimensions 2*4 = 8. | ||
- | =====Examples: | + | ====Examples: |
A single string is a row vector of characters like ' | A single string is a row vector of characters like ' | ||
- | [D]$ | + | |
- | abc | + | abc |
This is equivalent to: | This is equivalent to: | ||
- | [D]$1 | + | |
- | abc | + | abc |
A character array of size [2 x 6] named ' | A character array of size [2 x 6] named ' | ||
- | [E]$2 | + | |
- | Du.... | + | Du.... |
- | hier.. | + | hier.. |
Pay attention for the 2nd dimension: The length of each line determines the row dimension! Therefore $N, $1$N and $N$1 are treated identically in opposite to the other types. | Pay attention for the 2nd dimension: The length of each line determines the row dimension! Therefore $N, $1$N and $N$1 are treated identically in opposite to the other types. | ||
Zeile 210: | Zeile 210: | ||
' | ' | ||
- | [A]:0:2:3 | + | |
and no values appear. | and no values appear. | ||
Zeile 216: | Zeile 216: | ||
The tag line can be commented with the '#' | The tag line can be commented with the '#' | ||
- | [TagName]: | + | |
Empty lines can be inserted before a tag line: | Empty lines can be inserted before a tag line: | ||
Zeile 223: | Zeile 223: | ||
String1 | String1 | ||
- | [Tag2]& | + | |
- | StringListElement1 | + | StringListElement1 |
- | =====Header line===== | + | ====Header line==== |
Old style: In ASC-HD v2.0 the header line looks as following: | Old style: In ASC-HD v2.0 the header line looks as following: | ||
Zeile 252: | Zeile 252: | ||
If new variables are appended to an existing file, the number of digits must not be decreased to avoid a loss of data. Be aware that management of data precision is a critical drawback when using ASCII files. | If new variables are appended to an existing file, the number of digits must not be decreased to avoid a loss of data. Be aware that management of data precision is a critical drawback when using ASCII files. | ||
- | ======Comments====== | + | =====Comments===== |
Disk space is cheap today. Therefore it is recommended to use ' | Disk space is cheap today. Therefore it is recommended to use ' | ||
Zeile 260: | Zeile 260: | ||
Date and time of creation, host name, institution, | Date and time of creation, host name, institution, | ||
- | ======Guidelines for implementations of reading and writing routines====== | + | =====Guidelines for implementations of reading and writing routines===== |
+ | |||
+ | Line breaks deviating from the preferred DOS style should be accepted. | ||
+ | |||
+ | Before appending new variables to a file, check the trailing line break. It is a beloved feature to extract single variables from am ASC-HD file, but avoid dull searching for ' | ||
+ | |||
+ | Users will insert errors in ASCII files whenever possible. A fair reading function counts the found elements and displays the name of the variable and the line number of problems. | ||
- | Line breaks deviating from the preferred DOS style should be accepted. Before appending new variables to a file, check the trailing line break. It is a beloved feature to extract single variables from am ASC-HD file, but avoid dull searching for ' | + | There is no idea how to treat characters with more then 7 bits. Think of an additional unicode type, the TeX like ["a] for the german Umlaut-a, the ISO-Latin-1 [& |
fileformats/hdascii.txt · Zuletzt geändert: 2017/12/22 15:08 von oliver