Differences

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

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
lesson_1 [2013/07/26 14:29]
juliana
lesson_1 [2020/02/13 20:48]
danilo
Line 1: Line 1:
-===== Data structures and formats ​===== +{{ :​logo_logo.png?​400 |}} 
- +\\ 
- +\\ 
 +=====LESSON 1: Dinamica EGO data structures and file format=====   
 +\\
 ==== What will you learn? ==== ==== What will you learn? ====
 +\\
   * Dinamica EGO data structures   * Dinamica EGO data structures
   * Dinamica EGO file formats   * Dinamica EGO file formats
- +\\ 
-Dinamica EGO handles data in several formats, including raster maps or images, tables, matrices, and a Weights of Evidence coefficient file.[{{ :​tutorial:​cube_raster_dataset.jpg| A cube raster dataset}}]\\ +Dinamica EGO handles data in several formats, including raster maps or images, tables, matrices, and a Weights of Evidence coefficient file.\\ 
- +\\ 
- +For spatial data, Dinamica ​EGO supports raster datasets ​for most analyses, but vector can also be input and then transformed into raster or used in Python or R hybrid EGO operatorsGeo-referencing is mandatory, same projection ​and datumDinamica EGO virtualization machine can process maps with different spatial resolution ​and tie point
-For spatial data, Dinamica ​only supports raster datasets. Therefore you will need to prepare your dataset in a GIS package ​and then export the maps in one of the three formats specified belowAlthough geo-referencing is supported and neededall raster dataset in a model must have the same number of columns ​and rowsMoreover they must be tied to the same coordinate space and registration ​point \\ +\\ 
- +   * Dinamica EGO reads and writes raster data in many ways: check all the [[:​supported_map_formats|Supported Map Formats]] 
-Dinamica EGO reads and writes raster data in many ways: check all the [[:​supported_map_formats|Supported Map Formats]]\\ +   * Dinamica EGO supports ​most of the coordinate systems. 
- +\\ 
-Dinamica EGO supports ​all the affine ​coordinate systems ​wich includes most of the projections and datums used+<note important>​In map algebra, the null concept is very important to obtain an intelligible result from a model execution. Null means absence of data. Thus a map containing an irregular geographic area of interest, which does not completely cover the geographic plane, must contain a representation for the null cell. The value reserved for null cell representation may vary depending on the data cell type, i.e. the size in bits used to store the cell values of a map. Dinamica EGO supports data cell types as follows: 
- +\\ 
- +\\ 
-<note important>​In map algebra, the null concept is very important to obtain an intelligible result from a model execution. Null means absence of data. Thus a map containing an irregular geographic area of interest, which does not completely cover the geographic plane, must contain a representation for null cell. The value reserved for null cell representation may vary depending on the data cell type, i.e. the size in terms of bits used to store the cell values of a map. Dinamica EGO supports data cell types as follows: {{ :​tutorial:​data_cell_types.jpg |}}\\ Usually, the lowest negative value is used to represent the null value. For example -32768 for Signed 16 Bit Integer. ​Always choose ​a data cell type able to embrace ​the range of values contained in a variable. For example: elevation, varying from -10 meters to 4000 meters, must be represented as Signed 16 Bit Integer or IEEE 754 32 Bit Real.</​note>​ +{{ :​tutorial:​data_cell_types.jpg |}} 
- +\\ 
-<​note ​warning> You may need (and must) in some cases to define the null value when loading a Geotiff dataset, which lacks this definition ​(highly advised). Learn in [[tutorial:​building_a_simple_model|Building a simple model Lesson]] how to do this.</​note>​\\ +Usually, the lowest negative value is used to represent the null value. For example -32768 for Signed 16 Bit Integer. ​Choose ​a data cell type able to encompass ​the range of values contained in a variable. For example: elevation, varying from -10 meters to 4000 meters, must be represented as Signed 16 Bit Integer or IEEE 754 32 Bit Real. If there is more than one choice, choose always the most economical data format in number of bits</​note>​ 
- +<​note ​tip> You may need to define the null value when loading a Geotiff ​and some other dataset, which lacks this definition. Learn in [[tutorial:​building_a_simple_model|Building a simple model Lesson]] how to do this.</​note>​ 
-**Tables** are a convenient way to represent attribute data, usually pertaining to a certain geographic zone, for example: country, state or counties. Dinamica EGO can read data in Comma Separated Value format, in which the first column represents the key and the second, the value, as follows+\\ 
- +Tables are a convenient way to represent attribute data, usually pertaining to a certain geographic zone, for example: country, state or counties. Dinamica EGO can also read data in Comma Separated Value format. It is possible to use two different kinds of tables: [[:table type|tables]] ​and [[:lookup table type|lookup tables]]
- +\\ 
-^ Key  ^ Value  ^              +---- 
 +====Table==== 
 +\\ 
 +^ Key*  ^ Key2*  ^ Value  ^ Value2 ​ ^              
 +| 1  | 2  | 10  | 60  | 
 +| 2  | 6  | 30  | 40  |  
 +| 3  | 9  | 15  | 20  | 
 +\\ 
 +---- 
 +====Lookup Table==== 
 +\\ 
 +^ Key  ^ Value  ^
 | 1  | 10  | | 1  | 10  |
 | 2  | 30  |  | 2  | 30  | 
 | 3  | 15  |    | 3  | 15  |   
- +\\ 
-The first line of the table must contain the columns titles “Key” and the variable name, such as population, countries, etc. +The first line of the lookup ​table must contain the columns titles “Key” and the variable name, such as population, countries, etc. 
- +\\ 
-Transition matrix is also stored using this format; ​the only difference is that the key employs a composite algorism to represent a transition as follows:  +---- 
- +====Transition ​Matrix==== 
- +\\ 
-Key  ​^ ​Value  ​^ ​              +A transition ​matrix is also represented by the following format
-| 1.002  | 0.223567 ​ | +\\ 
-| 1.003  | 0.223567 ​ |  +To*  ^ From*  ​^ ​Rate  ​^ ​              
-| 2.001  | 0.024841 ​ |  +| 1  | 2  | 0.223567 ​ | 
-| 2.003  | 0.030573 ​ | +| 1  | 3  | 0.223567 ​ |  
-| 3.002  | 0.000348 ​ | +| 2  | 1  | 0.024841 ​ |  
- +| 2  | 3  | 0.030573 ​ | 
-Thus the previous table is equivalent to the following transition matrixNote that the diagonal values do not need to be filled in, nor are necessary the transitions equal to zero+| 3  | 2  | 0.000348 ​ | 
- +\\ 
-      ​^ 1  ^ 2  ^ 3  ^            +The previous table is equivalent to the following transition matrixNote that the diagonal values do not need to be filled in. 
-|**1**  ​|- ​ | 0.223567 ​ | 0.379618 ​ | +\\ 
-|**2**  ​|0.024841 ​ | -  | 0.030573 ​ | +   ^ 1  ^ 2  ^ 3  ^            
-|**3**  ​|0 ​ | 0  | -  |  +1  | -  | 0.223567 ​ | 0.379618 ​ | 
- +2  | 0.024841 ​ | -  | 0.030573 ​ | 
- +3  | 0  | 0  | -  |  
-Another supported format is the Weights of Evidence file a text file containing the Weights of Evidence coefficients. This file is obtained through the Weights of Evidence method used in the calibration process +\\ 
 +Another supported format is the Weights of Evidence filea text file containing the Weights of Evidence coefficients. This file is obtained through the Weights of Evidence method used in the calibration process ​of the model. 
 +\\
 <note tip> <note tip>
-TIP: You can edit this file directly on a text editor or using the Weights of Evidence graphical editor linked to [[:​load_weights|Load Weights Functor]].</​note>​+You can edit this file directly on a text editor or using the Weights of Evidence graphical editor linked to [[:​load_weights|Load Weights Functor]]. 
 +</​note>​ 
 +\\ 
 +Congratulations,​ you have successfully completed this lesson! 
 +\\ 
 +\\ 
 +☞[[:​lesson_2 | Next Lesson]] 
 +\\ 
 +☞[[:​guidebook_start| Back to Guidebook Start]]