Grass Tutorial

Total Page:16

File Type:pdf, Size:1020Kb

Grass Tutorial Grass Tutorial Moritz Lennert [email protected] Grass Tutorial by Moritz Lennert Published $Date: 2005/04/26 15:39:13 $ Geographic Resources Analysis Support System Tutorial (Please note, the current version only outlines the intended contents, pages may be missing!) Copyright (c) 2003 GRASS Development Team. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled "GNU Free Documentation License". Table of Contents I. Introduction........................................................................................................................1 1. About this tutorial....................................................................................................1 2. What is GRASS ? ......................................................................................................3 3. Credits........................................................................................................................5 II. Basics..................................................................................................................................7 4. Hardware and software requirements ..................................................................7 Hardware .............................................................................................................7 Basic Software .....................................................................................................7 Optional software ...............................................................................................7 5. Basic UNIX reference .............................................................................................11 6. Download and Install ............................................................................................13 Packages of GNU/Linux Distributions.........................................................13 Compilation of source code.............................................................................13 III. GRASS in 10 minutes - Quick Intro for Newbies .................................................15 7. How to Quickstart GRASS....................................................................................15 You have a GRASS database ...........................................................................15 You have a georeferenced data file, and know its geographical coordinates...............................................................................................16 You have a georeferenced raster file, but don’t know its geographical coordinates...............................................................................................16 You have a non-georeferenced data file ........................................................17 Other situations.................................................................................................17 8. The Most Important Commands to Get Started ................................................19 IV. GRASS Concepts..........................................................................................................21 9. GRASS structure.....................................................................................................21 10. GRASS commands ...............................................................................................23 11. Graphical User Interface .....................................................................................25 12. The GRASS Region ..............................................................................................27 What is the region.............................................................................................27 Why care about the region ..............................................................................27 How to work with the region .........................................................................27 How to change the default region..................................................................28 V. Start a Project..................................................................................................................31 13. Set-up your GRASS database .............................................................................31 14. Start running GRASS ...........................................................................................33 15. Planning and constructing a GRASS database ................................................35 General definition of a project area when using scanned maps ................35 Definition of a project area with predefined geographical resolution......36 Definition of the project area without a previously defined resolution ...37 16. Set-up your location.............................................................................................39 17. Manage your data ................................................................................................43 VI. Import Data ...................................................................................................................45 18. Supported formats ...............................................................................................45 19. Raster Import ........................................................................................................47 20. Vector Import ........................................................................................................49 21. Sites (point data) import......................................................................................51 VII. Display and Query Maps..........................................................................................53 22. Managing GRASS Monitors ...............................................................................53 Frames in monitors...........................................................................................53 23. Displaying Maps ..................................................................................................55 Colors .................................................................................................................55 Scripting the display of maps (and frames)..................................................55 24. Zooming and Panning.........................................................................................57 25. Adding Legends and Scales................................................................................59 26. Visualize in 3D with nviz ....................................................................................61 iii VIII. Digitize........................................................................................................................63 27. Digitizing Vector Maps........................................................................................63 Rules for Digitizing in Topological GIS.........................................................63 Digitizing Maps ................................................................................................63 Digitizing Areas ................................................................................................64 Digitizing of Elevation Isolines ......................................................................66 28. Processing Scanned Maps...................................................................................69 Geocoding of scanned maps ...........................................................................69 Gap free geocoding of multiple, adjacent, scanned maps ..........................72 IX. Manage Attributes and Classes .................................................................................75 29. Raster Categories and Attributes.......................................................................75 Viewing category values..................................................................................75 Changing category values...............................................................................75 30. Vector Categories and Attributes.......................................................................77 Viewing category values..................................................................................77 Changing category values...............................................................................77 31. Site Attributes .......................................................................................................79 32. Data Management with PostgreSQL.................................................................81 X. Analyze Maps .................................................................................................................83 33. Statistics and Reports...........................................................................................83 Modules for raster maps..................................................................................83 Modules for vector maps.................................................................................84 Modules for site maps......................................................................................84 34. Overlay and Patch Maps.....................................................................................87 35. Create Buffers........................................................................................................89
Recommended publications
  • Package 'Rgdal'
    Package ‘rgdal’ September 16, 2021 Title Bindings for the 'Geospatial' Data Abstraction Library Version 1.5-27 Date 2021-09-16 Depends R (>= 3.5.0), methods, sp (>= 1.1-0) Imports grDevices, graphics, stats, utils LinkingTo sp Suggests knitr, DBI, RSQLite, maptools, mapview, rmarkdown, curl, rgeos NeedsCompilation yes Description Provides bindings to the 'Geospatial' Data Abstraction Li- brary ('GDAL') (>= 1.11.4) and access to projection/transformation opera- tions from the 'PROJ' library. Please note that 'rgdal' will be retired by the end of 2023, plan tran- sition to sf/stars/'terra' functions using 'GDAL' and 'PROJ' at your earliest conve- nience. Use is made of classes defined in the 'sp' package. Raster and vector map data can be im- ported into R, and raster and vector 'sp' objects exported. The 'GDAL' and 'PROJ' libraries are ex- ternal to the package, and, when installing the package from source, must be correctly in- stalled first; it is important that 'GDAL' < 3 be matched with 'PROJ' < 6. From 'rgdal' 1.5-8, in- stalled with to 'GDAL' >=3, 'PROJ' >=6 and 'sp' >= 1.4, coordinate reference sys- tems use 'WKT2_2019' strings, not 'PROJ' strings. 'Windows' and 'macOS' binaries (includ- ing 'GDAL', 'PROJ' and their dependencies) are provided on 'CRAN'. License GPL (>= 2) URL http://rgdal.r-forge.r-project.org, https://gdal.org, https://proj.org, https://r-forge.r-project.org/projects/rgdal/ SystemRequirements PROJ (>= 4.8.0, https://proj.org/download.html) and GDAL (>= 1.11.4, https://gdal.org/download.html), with versions either (A) PROJ < 6 and GDAL < 3 or (B) PROJ >= 6 and GDAL >= 3.
    [Show full text]
  • Amateur Radio Software Distributed with (X)Ubuntu LTS Serge Stroobandt, ON4AA
    Amateur Radio Software Distributed with (X)Ubuntu LTS Serge Stroobandt, ON4AA Copyright 2014–2018, licensed under Creative Commons BY-NC-SA Introduction Amateur radio (also called “ham radio”), is a technical hobby Many ham radio stations are highly integrated with computers. Radios are interfaced with com- puters to aid with contact logging, propagation prediction, station spotting, antenna steering, signal (de)modulation and filtering. For many years, amateur radio software has been a bastion of Windows™ ap- plications developed by However, with the advent of the Rasperry Pi, amateur radio hobbyists are slowly but surely discovering GNU/Linux. Most of the software for GNU/Linux is available through package repositories. Such package repositories come by default with the GNU/Linux distribution of your choice. Package management systems offer many benefits in the form of security (you know what you are getting from whom) and ease-of-use (packages are upgraded automatically). No longer does one need to wander the back corners of the internet to find wne or updated software, exposing oneself to the risk of catching a computer virus. A number of GNU/Linux distributions offer freely installable ham-related packages under the “Amateur Radio” section of their main repository. The largest collection of ham radio packages is offeredy b OpenSuse and De- bian-derived distributions like Xubuntu LTS and Linux Mint, to name but a few. Arch Linux may also have whole bunch of ham related software in the Arch User Repository (AUR). 1 Synaptic One way to find and tallins ham radio packages on Debian-derived distros is by using the Synaptic graphical package manager (see Figure 1).
    [Show full text]
  • Comparison of Open Source Virtual Globes
    FOSS4G 2010 Comparison of Open Source Virtual Globes Mathias Walker Pirmin Kalberer Sourcepole AG, Bad Ragaz www.sourcepole.ch FOSS4G Barcelona 7.-9.9.10 Comparison of Open Source Virtual Globes About Sourcepole > GIS-Knoppix: first GIS live-CD > QGIS > Core developer > QGIS Mapserver > OGR / GDAL > Interlis driver > schema support for PostGIS driver > Ruby on Rails > MapLayers plugin > Mapfish server plugin FOSS4G Barcelona 7.-9.9.10 Comparison of Open Source Virtual Globes Overview > Multi-platform Open Source Virtual Globes > Installation > out-of-the-box application > Adding user data > Features > Demo movie > Comparison > User data > Technology > Desired Virtual Globe features FOSS4G Barcelona 7.-9.9.10 Comparison of Open Source Virtual Globes Open Source Virtual Globes > NASA World Wind Java SDK > ossimPlanet > gvSIG 3D > osgEarth > Norkart Virtual Globe > Earth3D > Marble > comparison to Google Earth FOSS4G Barcelona 7.-9.9.10 Comparison of Open Source Virtual Globes Test user data > Test data of Austrian skiing region Lech > projection: WGS84 (EPSG:4326) > OpenStreetMap WMS > winter orthophoto > GeoTiff, 20cm resolution, 4.5GB > KML Tile Cache > ski lifts, ski slopes, cable cars and POIs > KML > Shapefile > elevation (ASTER) > GeoTiff, ~30m resolution, 445MB FOSS4G Barcelona 7.-9.9.10 Comparison of Open Source Virtual Globes NASA World Wind Java SDK > created by NASA's Learning Technologies project > now developed by NASA staff and open source community developers FOSS4G Barcelona 7.-9.9.10 Comparison of Open Source Virtual Globes
    [Show full text]
  • The GNOME Desktop Environment
    The GNOME desktop environment Miguel de Icaza ([email protected]) Instituto de Ciencias Nucleares, UNAM Elliot Lee ([email protected]) Federico Mena ([email protected]) Instituto de Ciencias Nucleares, UNAM Tom Tromey ([email protected]) April 27, 1998 Abstract We present an overview of the free GNU Network Object Model Environment (GNOME). GNOME is a suite of X11 GUI applications that provides joy to users and hackers alike. It has been designed for extensibility and automation by using CORBA and scripting languages throughout the code. GNOME is licensed under the terms of the GNU GPL and the GNU LGPL and has been developed on the Internet by a loosely-coupled team of programmers. 1 Motivation Free operating systems1 are excellent at providing server-class services, and so are often the ideal choice for a server machine. However, the lack of a consistent user interface and of consumer-targeted applications has prevented free operating systems from reaching the vast majority of users — the desktop users. As such, the benefits of free software have only been enjoyed by the technically savvy computer user community. Most users are still locked into proprietary solutions for their desktop environments. By using GNOME, free operating systems will have a complete, user-friendly desktop which will provide users with powerful and easy-to-use graphical applications. Many people have suggested that the cause for the lack of free user-oriented appli- cations is that these do not provide enough excitement to hackers, as opposed to system- level programming. Since most of the GNOME code had to be written by hackers, we kept them happy: the magic recipe here is to design GNOME around an adrenaline response by trying to use exciting models and ideas in the applications.
    [Show full text]
  • Wxwidgets Un Framework Per Realizzare Applicazioni Con Interfaccia Utente Nativa
    wxWidgets un framework per realizzare applicazioni con interfaccia utente nativa relatore Marco Cavallini Libertà I tradizionali gradi di libertà Open Source: libertà di utilizzo gratuito libertà di modifica libertà dalla dipendenza verso un fornitore Con wxWidgets possiamo aggiungere: libertà di utilizzare un'applicazione su qualunque piattaforma ...? 2 Contenuti Contenuti Cos'è wxWidgets? Piattaforme supportate Illustrazioni Per cosa piace wxWidgets? Portabilità API Tools per lo sviluppatore Storia Applicazioni di esempio 3 Cos'è wxWidgets? wxWidgets aiuta nello sviluppo di applicazioni che sono: multi-piattaforma multi-lingua realmente native veloci facili da usare facili da scrivere dall'aspetto professionale free o commerciali robuste 4 Cos'è wxWidgets? (cont'd) wxWidgets consiste di: C++ API (1) un set di librerie, una per piattaforma un manuale di 1700 pagine una collezione di oltre 70 esempi un help viewer e altri tools una comunità di sviluppatori (1) also available for Python, Perl, Basic, JavaScript, Lua, Eiffel 5 Cos'è wxWidgets? (cont'd) Alcune statistiche: oltre 300 classi oltre 5.000 funzioni oltre 1,3 milioni di linee di codice è un prodotto maturo : oltre 10 anni di età costo stimato di sviluppo 41MLN di $ in Dicembre 2001 circa 1.500 sottoscrittori della mailing lists (wxWidgets + wxPython) 6 Piattaforme supportate wxWidgets API wxMSW wxGTK wxX11 wxMotif wxMac wxOS2 Classic or WIN32 GTK+ Xlib Motif/Lesstif Carbon Carbon PM Windows Unix/Linux MacOS 9MacOS X OS/2 Key: Port GUI OS Other variants: Unix variants: wxBase – non-GUI subset of wxWidgets API Linux x86, Linux S/390, wxMGL – port to SciTech's MGL layer OpenBSD, FreeBSD, NetBSD, wxMSW/Univ – WIN32 port using own widget set Solaris, Darwin, AIX, HP-UX, IRIX, wxMSW apps on Wine; wxMSW compiled with Winelib SCI UnixWare, DEC OSF/1 wxGTK/wxX11 on MacOS X under X11 (e.g.
    [Show full text]
  • Remotely Execute GRASS GIS Scripts on Your Server
    g.remote Remotely execute GRASS GIS scripts on your server Vaclav Petras Center for Geospatial Analytics OSGeo Research and Education Laboratory North Carolina State University May 7, 2015 cba GRASS GIS: g.remote NCSU Center for Geospatial Analytics 1 / 12 Server for everybody there are servers, HPC clusters, clouds lying around once somebody set it up, it’s easy to get to it if you know what ssh -X means and you also want to work locally in the same environment GRASS GIS: g.remote NCSU Center for Geospatial Analytics 2 / 12 Tangible Landscape currently locked to MS Windows desktop needs powerful processing backend for larger simulations pure in-cloud or client-server with WPS would be overkill GRASS GIS: g.remote NCSU Center for Geospatial Analytics 3 / 12 g.remote developed for hybrid desktop-server workflow tests of processing or part of processing locally store and process the big data on a server synchronous processing easily to integrate into scripts GRASS GIS: g.remote NCSU Center for Geospatial Analytics 4 / 12 Usage Basic call in command line g.remote user=john server=example.com \ grassdata=/grassdata \ location=nc_spm mapset=practice1 \ grass_script=/path/to/script.py data are stored on the server Python script is local and transferred to the server GRASS GIS: g.remote NCSU Center for Geospatial Analytics 5 / 12 Usage Addition of inputs and outputs g.remote ... \ raster=elevation \ output_raster=waterflow data are transfered to and from the server GRASS GIS: g.remote NCSU Center for Geospatial Analytics 6 / 12 Usage GRASS GIS: g.remote NCSU Center for Geospatial Analytics 7 / 12 Architecture Three layers connection to server (class) Paramiko ssh + scp (OpenSSH Client) can accommodate web-based applications or local programs GRASS session (class) runs GRASS modules, scripts and Python code inside GRASS session using the connection transports GRASS data (maps, region, .
    [Show full text]
  • Metadefender Core V4.12.2
    MetaDefender Core v4.12.2 © 2018 OPSWAT, Inc. All rights reserved. OPSWAT®, MetadefenderTM and the OPSWAT logo are trademarks of OPSWAT, Inc. All other trademarks, trade names, service marks, service names, and images mentioned and/or used herein belong to their respective owners. Table of Contents About This Guide 13 Key Features of Metadefender Core 14 1. Quick Start with Metadefender Core 15 1.1. Installation 15 Operating system invariant initial steps 15 Basic setup 16 1.1.1. Configuration wizard 16 1.2. License Activation 21 1.3. Scan Files with Metadefender Core 21 2. Installing or Upgrading Metadefender Core 22 2.1. Recommended System Requirements 22 System Requirements For Server 22 Browser Requirements for the Metadefender Core Management Console 24 2.2. Installing Metadefender 25 Installation 25 Installation notes 25 2.2.1. Installing Metadefender Core using command line 26 2.2.2. Installing Metadefender Core using the Install Wizard 27 2.3. Upgrading MetaDefender Core 27 Upgrading from MetaDefender Core 3.x 27 Upgrading from MetaDefender Core 4.x 28 2.4. Metadefender Core Licensing 28 2.4.1. Activating Metadefender Licenses 28 2.4.2. Checking Your Metadefender Core License 35 2.5. Performance and Load Estimation 36 What to know before reading the results: Some factors that affect performance 36 How test results are calculated 37 Test Reports 37 Performance Report - Multi-Scanning On Linux 37 Performance Report - Multi-Scanning On Windows 41 2.6. Special installation options 46 Use RAMDISK for the tempdirectory 46 3. Configuring Metadefender Core 50 3.1. Management Console 50 3.2.
    [Show full text]
  • Assessmentof Open Source GIS Software for Water Resources
    Assessment of Open Source GIS Software for Water Resources Management in Developing Countries Daoyi Chen, Department of Engineering, University of Liverpool César Carmona-Moreno, EU Joint Research Centre Andrea Leone, Department of Engineering, University of Liverpool Shahriar Shams, Department of Engineering, University of Liverpool EUR 23705 EN - 2008 The mission of the Institute for Environment and Sustainability is to provide scientific-technical support to the European Union’s Policies for the protection and sustainable development of the European and global environment. European Commission Joint Research Centre Institute for Environment and Sustainability Contact information Cesar Carmona-Moreno Address: via fermi, T440, I-21027 ISPRA (VA) ITALY E-mail: [email protected] Tel.: +39 0332 78 9654 Fax: +39 0332 78 9073 http://ies.jrc.ec.europa.eu/ http://www.jrc.ec.europa.eu/ Legal Notice Neither the European Commission nor any person acting on behalf of the Commission is responsible for the use which might be made of this publication. Europe Direct is a service to help you find answers to your questions about the European Union Freephone number (*): 00 800 6 7 8 9 10 11 (*) Certain mobile telephone operators do not allow access to 00 800 numbers or these calls may be billed. A great deal of additional information on the European Union is available on the Internet. It can be accessed through the Europa server http://europa.eu/ JRC [49291] EUR 23705 EN ISBN 978-92-79-11229-4 ISSN 1018-5593 DOI 10.2788/71249 Luxembourg: Office for Official Publications of the European Communities © European Communities, 2008 Reproduction is authorised provided the source is acknowledged Printed in Italy Table of Content Introduction............................................................................................................................4 1.
    [Show full text]
  • Gnuplot Programming Interview Questions and Answers Guide
    Gnuplot Programming Interview Questions And Answers Guide. Global Guideline. https://www.globalguideline.com/ Gnuplot Programming Interview Questions And Answers Global Guideline . COM Gnuplot Programming Job Interview Preparation Guide. Question # 1 What is Gnuplot? Answer:- Gnuplot is a command-driven interactive function plotting program. It can be used to plot functions and data points in both two- and three-dimensional plots in many different formats. It is designed primarily for the visual display of scientific data. gnuplot is copyrighted, but freely distributable; you don't have to pay for it. Read More Answers. Question # 2 How to run gnuplot on your computer? Answer:- Gnuplot is in widespread use on many platforms, including MS Windows, linux, unix, and OSX. The current source code retains supports for older systems as well, including VMS, Ultrix, OS/2, MS-DOS, Amiga, OS-9/68k, Atari ST, BeOS, and Macintosh. Versions since 4.0 have not been extensively tested on legacy platforms. Please notify the FAQ-maintainer of any further ports you might be aware of. You should be able to compile the gnuplot source more or less out of the box on any reasonable standard (ANSI/ISO C, POSIX) environment. Read More Answers. Question # 3 How to edit or post-process a gnuplot graph? Answer:- This depends on the terminal type you use. * X11 toolkits: You can use the terminal type fig and use the xfig drawing program to edit the plot afterwards. You can obtain the xfig program from its web site http://www.xfig.org. More information about the text-format used for fig can be found in the fig-package.
    [Show full text]
  • Python Scripting for Spatial Data Processing
    Python Scripting for Spatial Data Processing. Pete Bunting and Daniel Clewley Teaching notes on the MSc's in Remote Sensing and GIS. May 4, 2013 Aberystwyth University Institute of Geography and Earth Sciences. Copyright c Pete Bunting and Daniel Clewley 2013. This work is licensed under the Creative Commons Attribution-ShareAlike 3.0 Unported License. To view a copy of this license, visit http://creativecommons. org/licenses/by-sa/3.0/. i Acknowledgements The authors would like to acknowledge to the supports of others but specifically (and in no particular order) Prof. Richard Lucas, Sam Gillingham (developer of RIOS and the image viewer) and Neil Flood (developer of RIOS) for their support and time. ii Authors Peter Bunting Dr Pete Bunting joined the Institute of Geography and Earth Sciences (IGES), Aberystwyth University, in September 2004 for his Ph.D. where upon completion in the summer of 2007 he received a lectureship in remote sensing and GIS. Prior to joining the department, Peter received a BEng(Hons) in software engineering from the department of Computer Science at Aberystwyth University. Pete also spent a year working for Landcare Research in New Zealand before rejoining IGES in 2012 as a senior lecturer in remote sensing. Contact Details EMail: [email protected] Senior Lecturer in Remote Sensing Institute of Geography and Earth Sciences Aberystwyth University Aberystwyth Ceredigion SY23 3DB United Kingdom iii iv Daniel Clewley Dr Dan Clewley joined IGES in 2006 undertaking an MSc in Remote Sensing and GIS, following his MSc Dan undertook a Ph.D. entitled Retrieval of Forest Biomass and Structure from Radar Data using Backscatter Modelling and Inversion under the supervision of Prof.
    [Show full text]
  • Glossaire Infographique
    Glossaire Infographique André PASCUAL [email protected] Glossaire Infographique Table des Matières GLOSSAIRE ILLUSTRÉ...............................................................................................................................................................1 des Termes techniques & autres,.....................................................................................................................................1 Prologue.......................................................................................................................................................................................2 Notice Légale...............................................................................................................................................................................3 Définitions des termes & Illustrations.......................................................................................................................................4 −AaA−...........................................................................................................................................................................................5 Aberration chromatique :..................................................................................................................................................5 Accrochage − Snap :........................................................................................................................................................5 Aérosol,
    [Show full text]
  • GRASS GIS 6.3 Command List
    d.erase Erase the contents of the active display frame with user defined color d.extend Set window region so that all currently displayed raster, vector and sites maps can be shown in a monitor. d.extract Select and extract vectors with mouse into new vector map d.font.freetype Selects the font in which text will be displayed on the user’s graphics monitor. d.font Selects the font in which text will be displayed on the user’s graphics monitor. d.frame Manages display frames on the user’s graphics monitor. GRASS GIS 6.3 Command list d.geodesic Displays a geodesic line, tracing the shortest distance between two geographic points 20 Novermber 2006 along a great circle, in a longitude/latitude data set. d.graph Program for generating and displaying simple graphics on the display monitor. d.grid Overlays a user-specified grid in the active display frame on the graphics monitor. Command types: d.his Displays the result obtained by combining hue, intensity, and saturation (his) values from user-specified input raster map layers. d.* display commands d.histogram Displays a histogram in the form of a pie or bar chart for a user-specified raster file. db.* database commands d.info Display information about the active display monitor g.* general commands d.labels Displays text labels (created with v.label) to the active frame on the graphics monitor. i.* imagery commands d.legend Displays a legend for a raster map in the active frame of the graphics monitor. m.* miscellanous commands d.linegraph Generates and displays simple line graphs in the active graphics monitor display ps.* postscript commands frame.
    [Show full text]