Changes for page DIF

Last modified by Kashif Iqbal on 2019/03/13 16:46

From version < 3.1 >
edited by Kashif Iqbal
on 2019/03/08 16:01
To version < 4.1 >
edited by Kashif Iqbal
on 2019/03/11 13:16
< >
Change comment: There is no comment for this version

Summary

Details

Page properties
Content
... ... @@ -10,6 +10,34 @@
10 10  
11 11  DIF store spreadsheet contents in ASCII text file that allows it to be viewed and edited with a text editor. The format owns its place in data serialization formats list for its characteristics of data interchange. A DIF file consists of 2 sections; a header and data.
12 12  
13 +Everything in DIF is represented by a 2- or 3-line chunk. Headers get a 3-line chunk; data, 2. Header chunks start with a text identifier that is all caps, only alphabetic characters, and less than 32 letters. The following line must be a pair of numbers, and the third line must be a quoted string. On the other hand, data chunks start with a number pair and the next line is a quoted string or a keyword.
14 +
15 +=== Values ===
16 +
17 +A value occupies two lines, the first a pair of numbers and the second either a string or a keyword. The first number of the pair indicates type:
18 +
19 +* −1 – directive type, the second number is ignored, the following line is one of these keywords:
20 +** BOT – beginning of tuple (start of row)
21 +** EOD – end of data
22 +* 0 – numeric type, value is the second number, the following line is one of these keywords:
23 +** V – valid
24 +** NA – not available
25 +** ERROR – error
26 +** TRUE – true boolean value
27 +** FALSE – false boolean value
28 +* 1 – string type, the second number is ignored, the following line is the string in double quotes
29 +
30 +=== Header chunk ===
31 +
32 +A header chunk is composed of an identifier line followed by the two lines of a value.
33 +
34 +* TABLE - a numeric value follows of the version, the disused second line of the value contains a generator comment
35 +* VECTORS - the number of columns follows as a numeric value
36 +* TUPLES - the number of rows follows as a numeric value
37 +* DATA - after a dummy 0 numeric value, the data for the table follow, each row preceded by a BOT value, the entire table terminated by an EOD value
38 +
39 +The numeric values in header chunks use just an empty string instead of the validity keywords.
40 +
13 13  === Example ===
14 14  
15 15  Following example shows the contents of a simple worksheet and its equivalent DIF representation.