Tuesday, May 11, 2010

GIS Part-II Maps

What is Map :-

        Map is representation of real world. A map represents geographic features or other spatial phenomena by graphically conveying information about locations and attributes. Locational information describes the position of particular geographic features on the Earth's surface, as well as the spatial relationship between features, such as the shortest path from a fire station to a library, the proximity of competing businesses, and so on. Attribute information describes characteristics of the geographic features represented, such as the feature type, its name or number and quantitative information such as its area or length.

Thus the basic objective of mapping is to provide
  1) descriptions of geographic phenomenon
  2) spatial and non spatial information
  3) map features like Point, Line, & Polygon.


Benefits of Maps :-
      Suppose we want to find a buried treasure. The only person who knows where the treasure is, cannot travel with us. How will we find the treasure? The individual who knows where the treasure is could describe to us in great detail how to get to and find the treasure. This might work, but what happens if we forget an important part of the instructions? We would have to travel all the way back and have them repeat again, the description of where the treasure is hidden. We could have them write the description down for us. That way, we will not forget it. Having these instructions in hand, we can easily refer back to them as needed. A list of written directions would be a more useful tool, but what would happen if we got lost? Once we were off course, the written directions would no longer be of any use to us. These instructions only specified how to find the treasure from one specific starting point, and not from our current, lost position. A map solves both of these problems.

Map Reading :-


      Maps are the basic tools of geography. They enable us to depict spatial phenomenon on paper. There are conventions used in cartography which allow a map to be read efficiently and quickly.

      A good map will have a legend or key which will show the user what different symbols mean. For instance, a square with a flag on top usually represents a school and roads are represented by a variety of widths and combinations of lines. Often a dashed line represents a border.

   Note, however, that map symbols used in the differently in different countries.


      The symbol for a secondary highway on a USGS Topographic map is equivalent to a railroad in Switzerland. Make sure to read the legend and you'll understand the symbols.
Every map is a representation of a larger portion of the earth. Read the feature about scale to learn more about how to determine the distance on earth represented on the map.

         Without a north arrow, it is difficult to determine the orientation of a map. With a north arrow (pointing in the correct direction), a user can determine direction. Some maps, such as topographic maps, will point to "true north" (the north pole) and to magnetic north (where your compass points, to northern Canada). Usually, you won't see something quite as detailed as a compass rose but a map does need to provide orientation.
    
         A neatline is the border of a map. It helps to define the edge of the map area and obviously keeps things looking "neat."
    
         Since the map is a flat representation of the curved surface of the earth, all maps are inherently inaccurate. There are a variety of projections which have been formulated for different uses.
A map's title provides important clues about the cartographer's intentions and goals. You can hope to expect entirely different information on a map titled "Unemployment in Jefferson County" versus "Topography of Mount St. Helens."

          Color appears so often on maps that we often take it for granted that mountains are brown and rivers are blue. Just as there are many types of color maps, there are also many different color schemes used by cartographers. The map user should look to the legend for an explanation of colors on a map.
Our expectations of colors on a map leads to some problems when it is used for elevation. Elevation is often represented as a sequence of dark greens (low elevation or even below sea level) to browns (hills) to white or gray (highest elevation). Since many people associate green with a fertile region, many map users will see lower elevations, which may be deserts, and assume those areas are filled with lush vegetation. Also, people may see the reds and browns of mountains and assume that they are barren, Grand Canyon-type landscapes of desolation but the mountains may be forested and covered in brush.

       Additionally, as water always appears bright blue on a map, the user is often inclined to visualize any water on a map as pristine and clear blue - even though it might be entirely different color due to pollution.

Types of Maps :-


       There are several types of maps. Each show different information. Most maps include a compass rose, which indicates which way is north, south, east and west. They also include a scale so you can estimate distances. Here's a look at some different types of maps.

1 Topographic maps
2 Thematic Maps
3 Climate maps
4 Economic Maps
5 Political Maps
6 Agricultural Maps
7 Physical Maps
8 Demographic Maps
9 Meteorological Maps
10 Pictorial Maps
11 Geological Maps
12 Contour Maps and more...
GIS - Part I

GIS stands for “Geographical Information System” The term GIS has number of definitions. But We can easily understand that It is simply “Location” or Location based technology

Still there are number of definitions have defined that is

“GIS is a method of using computer systems to collect, organize, manipulate and display geographic data to answer questions about the world. It is a system designed to combine many different types of geographic features and analyze the relationships between them in a single framework. “

Maps have been used for thousands of years, but it is only within the last few decades that the technology has existed to combine maps with computer graphics and databases to create geographic information systems or GIS. The themes in the above graphic are only a small example of the wide array of information that can view or analyze with a GIS.

GIS is used to display and analyze spatial data which are tied to databases. This connection is what gives GIS its power: maps can be drawn from the database and data can be referenced from the maps. When a database is updated, the associated map can be updated as well. GIS databases include a wide variety of information including: geographic, social, political, environmental, and demographic.

It is estimated that approximately 80% of all information has a "spatial" or geographic component. In other words, most information is tied to a place. So when making decisions about siting new facilities, creating hiking trails, protecting wetlands, directing emergency response vehicles, designating historic neighborhoods or redrawing legislative districts, geography plays a significant role.
This is where GIS comes in. Geographic Information Systems (GIS) technology is a computer-based data collection, storage, and analysis tool that combines previously unrelated information into easily understood maps. But GIS is much more than maps. A GIS can perform complicated analytical functions and then present the results visually as maps, tables or graphs, allowing decision-makers to virtually see the issues before them and then select the best course of action.
Add the Internet, and GIS offers a consistent and cost-effective means for the sharing and analysis of geographic data among government agencies, private industry, non-profit organizations, and the general public.

GIS is a program that allows for the easy use and understanding of geographical information, enabling the user to view and interpret a wide range and depth of data spatially while revealing important patterns and relationships. GIS is a useful tool for examining a wide variety of issues, including city planning, transportation, human health, environmental management and conservation, and cultural resources preservation.


The above screen shows representation of real world in GIS

continues …... Part -II

How to Import Shape Files into RDBMS( PostgreSQL/POSTGIS)

How to Store Spatial Data or Shape Files into RDBMS( PostgreSQL/POSTGIS)




1 What is Shape file ?


   The shape file is coined by ESRI(Environmental System Research Institute).The shape file stores individual data type(Polygon or line or Point).The shape file is combination of different files (that is from 4 to 5 files combination)
        .shp
        .shx
        .dbf
        .xml
        .prj


2 )Why Spatial data should store in RDBMS ?


  The shape files are combination of files,if one file is missed ,the shape file will not work. Those are just static files , these files suppose to store in local disc ,single user access and the file sometimes can be corrupted or misplaced .So that the data will be lost.The data should store in the database.


How to store shape file into database(RDBMS) ?


There are different steps involved … that is


3) Install PostrgreSQL (Open source)
Referred URLs are


http://pginstaller.projects.postgresql.org/


or


http://askoh.net/misc/visualworks/installPostgreSQL/


4) Install PostGIS


http://www.gpsfiledepot.com/tutorials/installing-and-setting-up-postgresql-with-postgis/




5) Set Environment variables for shp2pgsql.exe




My Computer → Properties → Advanced → select Environment Variables


6) command for importing shapefile..blow are the steps
  
     i) Open commandline (Clt +r ->type cmd)
     ii)set shapefile path in commandline
     iii) And run below query
  
  shp2pgsql -s 24047 india.shp india > india.sql


About command :-
   24047 : is SRID
   india.shp : is shapefile name
   india :- is table name, the name which suppose to import into database
   india.sql :- is sql file,which suppose to run in the query builder


    


7) Convert Shape file to PostgreSQL/POSTGIS :-


8)  Run Sql Converted SQL file


and finally table will import into database postgresql and we can see the geometry column added in the imported table in the database.