330 likes | 673 Views
Chapter 7 ATTRIBUTE DATA MANAGEMENT 属性数据管理. 7.1 Attribute Data in GIS GIS 中的属性数据 7.2 The Relational Model 关系数据库模型 7.3 Attribute Data Entry 属性数据输入 7.4 Manipulation of Fields and Attribute data 字段与属性数据的处理. Chapter 7ATTRIBUTE DATA INPUT AND MANAGEMENT 属性数据的输入与管理.
E N D
Chapter 7ATTRIBUTE DATA MANAGEMENT属性数据管理 • 7.1 Attribute Data in GIS GIS中的属性数据 • 7.2 The Relational Model 关系数据库模型 • 7.3 Attribute Data Entry 属性数据输入 • 7.4 Manipulation of Fields and Attribute data 字段与属性数据的处理
Chapter 7ATTRIBUTE DATA INPUT AND MANAGEMENT属性数据的输入与管理 • Attribute data - describes characteristics of spatial features 属性数据-描述空间要素的特征 • Georelational data model stores spatial and attribute data separately 地理关系数据模型将空间数据和属性数据分开存储 • Object-based data model stores attributes and spatial data together 基于对象数据模型将空间数据与属性数据存在同一数据库中 • Raster data model - cell values and frequencies 栅格数据模型 - 格网单元值和所出现的频率
Figure 7.1 Each street segment in the TIGER/Line files has a set of associated attributes. These attributes include street name, address ranges on the left side and the right side, as well as ZIP codes on both sides.
Figure 7.2 As an example of the georelational data model, the soils coverage uses SOIL-ID to link to the spatial and attribute data.
Figure 7.3 The object-based data model uses the Shape field to store the geometry of soil polygons. The table therefore contains both spatial and attribute data.
Figure 7.4 A value attribute table lists the attributes of value and count. The value field refers to the cell value, and the count field refers to the number of cells. A value attribute table differs from the feature attribute tables in Figures 6.2 and 6.3.
7.1 Attribute Data in GIS地理信息系统中的属性数据 • Stored in tables 保存在表中 • Rows represent spatial features (records) 行代表空间要素(记录) • Columns describe a characteristic (fields) 列描述特征(字段) • Intersection of a row and a column shows value of a particular characteristic for a particular feature 行与列的交叉点确定特定要素的特定属性值
Figure 7.5 A feature attribute table consists of rows and columns. Each row represents a spatial feature, and each column represents a property or characteristic of the spatial feature.
7.1.1 Type of Attribute Table属性表的类型 • Two types of attribute tables 两种属性表 • Feature attribute table 要素属性表 • Non-spatial, table does not have direct access to feature geometries 非空间属性表,不直接涉及要素的几何形状
7.1.2 Database Management数据库管理 • Database management system (DBMS) to manage tables 数据库管理系统是对表的管理
7.1.3 Types of Attribute Data属性数据类型 • Data type 数据类型 • Number, text (or character), date, binary large object (BLOB) 数字型,文本型(或字符),日期型,二进制大对象 • Measurement scale 量测标尺 • Nominal, ordinal, interval, ratio data 标称的, 有序的,区间的,比率的 • Nominal and ordinal - categorical data 标称数据和有序数据---类别数据 • Interval and ratio - numeric data 区间数据和比率数据---数值数据
7.2 The Relational Model关系数据库模型 • Four database designs 四种数据库设计类型 • Flat file 平面文件 • Hierarchical database 层次数据库 • Network database 网络数据库 • Relational database 关系数据库 • Primary key, foreign key 主键, 外键
Figure 7.6 Four types of database design: (a) flat file, (b) hierarchical, (c) network, and (d) relational.
7.2.1 MUIR: A Relational Database Model关系数据库举例 • Map Unit Interpretation Record 地图单元解译记录 • To link SSURGO data by soil physical and chemical properties 通过土壤的理化性质连接全世界的国家范围的土壤地理调查数据库
7.2.2 Normalization 正规化 • Breaking a table down into smaller tables while maintaining linkages to 将一个表分解成较小的表格,同时保持它们之间的必要链接 • Avoid redundant data 避免数据冗余 • Ensure that attribute data in separate tables can be maintained and updated separately 确保单独表格中属性数据可以被单独维护、更新 • To facilitate a distributed database 有利于形成分布式数据库
PIN Owner Owner address Sale date Acres Zone code Zoning P101 Wang 101 Oak St 1-10-98 1.0 1 residential Chang 200 Maple St P102 Smith 300 Spruce Rd 10-6-68 3.0 2 commercial Jones 105 Ash St P103 Costello 206 Elm St 3-7-97 2.5 2 commercial P104 Smith 300 Spruce Rd 7-30-78 1.0 1 residential TABLE 7.1 An Unnormalized Table
PIN Owner Owner address Sale date Acres Zone code Zoning P101 Wang 101 Oak St 1-10-98 1.0 1 residential P101 Chang 200 Maple St 1-10-98 1.0 1 residential P102 Smith 300 Spruce Rd 10-6-68 3.0 2 commercial P102 Jones 105 Ash St 10-6-68 3.0 2 commercial P103 Costello 206 Elm St 3-7-97 2.5 2 commercial P104 Smith 300 Spruce Rd 7-30-78 1.0 1 residential TABLE 7.2 First Step in Normalization
Figure 7.7 Separate tables from the second step in normalization. The keys relating the tables are highlighted.
Figure 7.8 Separate tables after normalization. The keys relating the tables are highlighted.
7.2.3 Types of Relationships Figure 7.9 Four types of data relationship between tables: one-to-one, one-to-many, many-to-one, and many-to-many.
Figure 7.10 Primary key and foreign key provide the linkage to join the table on the right to the feature attribute table on the left.
Figure 7.11 This example of a many-to-one relationship in the MUIR database relates three map unit components in comp.dbf to the same soil class in the taxclass.dbf.
Figure 7.12 This example of a one-to-many relationship in the MUIR database relates one map unit component in comp.dbf to four layers in layer.dbf.
7.2.4 Join and Relate Tables表的连接与关联 • Relational database allows attribute data in separate tables to be linked 关系数据库允许属性表被单独链接 • Join brings together two tables by using a common key 连接表是指把两个表用共同的关键字连接起来 • Relate temporarily connects two tables but keeps them physically separate 关联表是指把两个表联系起来但是保持独立性
7.3 Attribute Data Entry属性数据的输入 • Similar to digitizing from a paper map 同空间数据的数字化相似 • Requires setup of fields, data entry, and verification of attribute values 要求字段的建立,数据输入和属性值的校正
7.3.1 Field Definition 字段定义 • Usually includes field name, data width, data type, and number of decimal digits 一般包括字段名,数据宽度,数据类型和小数位数 • Width refers to the number of spaces reserved for a field 宽度指存储一个字段所需要的空间
7.3.2 Method of Data Entry 数据输入方法 • Search for existing data 寻找已经存在的数据 • If attribute data files do not exist, typing is the only option 如果属性数据文件不存在,键盘输入是唯一的选择
7.3.3 Attribute Data Verification属性数据的校核 • Make sure that attribute data are linked to spatial data 确保属性数据与空间数据正确关联 • Verify accuracy of data 检查数据的准确性 • Manual verification 人工校对 • Computer search 计算机检查
7.4 Manipulation of Fields and Attribute Data字段与属性数据的处理 • Field management includes adding or deleting fields, creating new fields through classification, and computation of existing attribute data 字段操作包括字段的添加或删除,通过分类创建新的字段和计算已有属性数据
7.4.1 Add and Delete Fields添加和删除字段 • Often existing data contains either more or fewer fields than we need 通常已有数据包含比我们所需要的数据或多或少的字段 • Delete unneeded fields to save computer processing time and data storage needs 删除不需要的字段可以节省计算机处理和存储数据所需时间 • Adding a field is required prior to classification or computation 在进行分类或计算之前要求先添加一个字段
7.4.2 Classification of Attribute Data属性数据的分类 • Creating new attribute data through classification 通过分类创建新的属性数据 • Reduces data set to small number of classes 减少数据集以达到较少类型数目 • Three steps 三步 • Defining new field for saving results of classification 定义新的字段以存储分类结果 • Selecting a data subset through query 通过查询选择一个数据子集 • Assigning a value to the selected subset 对选择的数据子集赋值
7.4.3 Computation of Attribute Data属性数据的计算 • New created from existing through computation 通过计算从已有数据中创建新的数据 • New field “feet” from existing field “meters” 新字段“feet”是从已有字段“meters”创建的 • Areas, densities, etc. 面积,密度等