User Tools

Site Tools


howtos:workwithdata:coordexample

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
howtos:workwithdata:coordexample [2010/01/19 16:08]
deryn.crockett created
howtos:workwithdata:coordexample [2010/01/19 16:28] (current)
deryn.crockett
Line 1: Line 1:
-===== Data Format Examples =====+===== Coordinate ​Data Format Examples =====
  
 The following examples will use the array object **pop[c,​s,​t]** which contains population data for North America by country, sex, and time where The following examples will use the array object **pop[c,​s,​t]** which contains population data for North America by country, sex, and time where
Line 9: Line 9:
 t is the sequence time from 2000 to 2004 t is the sequence time from 2000 to 2004
  
-==== Coordinate Data Format ​====+==== allCoord=off ​====
  
-=== allCoord=off === +If the allCoord parameter is set to off, data from the rightmost index are placed in columns. ​ The import file may appear as follows:
- +
-If the allCoord parameter is set to off, data from the rightmost index are placed in columns. ​ The import file would appear as follows:+
  
 <​file>​ <​file>​
 !Years ​ 2000 2001 2002 2003 2004 !Years ​ 2000 2001 2002 2003 2004
-Canada male 10 12 14 16 18 
 Canada ​ female ​ 12 14 16 18 20 Canada ​ female ​ 12 14 16 18 20
 US  male  100 120 140 160 180 US  male  100 120 140 160 180
 Mexico female ​ 20 22 24 26 28 Mexico female ​ 20 22 24 26 28
 +Canada male 10 12 14 16 18
 </​file>​ </​file>​
  
-Note that with coordinate format, there does not need to be data for every member of the set.  (In the above example, US female and Mexico male are not in the file.) ​ However, the row labels in the import file must match the element names of the set.+Note that with coordinate format, there does not need to be data for every member of the set and the rows can be in any order.  (In the above example, US female and Mexico male are not in the file.) ​ However, the row labels in the import file must match the element names of the set.  TOOL matches the labels to the element names to determine where to put the data in the object array.
  
-=== allCoord=on ===+==== allCoord=on ​====
  
-If the allCoord parameter is set to on, all data are in a single column. ​ The import file would appear as follows:+If the allCoord parameter is set to on, all data are in a single column. ​ The import file may appear as follows:
  
 <​file>​ <​file>​
-Canada male 2000 10  
-Canada male 2001 12  
-Canada male 2002 14  
-Canada male 2003 16  
-Canada male 2004 18 
 Canada ​ female ​ 2000 12  Canada ​ female ​ 2000 12
 Canada female 2001 14  Canada female 2001 14
Line 50: Line 43:
 Mexico female ​ 2003 26 Mexico female ​ 2003 26
 Mexico female ​ 2004 28 Mexico female ​ 2004 28
 +Canada male 2000 10
 +Canada male 2001 12
 +Canada male 2002 14
 +Canada male 2003 16
 +Canada male 2004 18
 </​file>​ </​file>​
  
howtos/workwithdata/coordexample.1263917297.txt.gz · Last modified: 2010/01/19 16:08 by deryn.crockett