Monday, April 4, 2016

Getting Started With Python Programming in QGIS


How to start python Programming in QGIS, lets write a simple "Hello world!" script.

QGIS is one of the best open source GIS software available. It has support for scripting in Python programming language. This means you can extend the functionality of QGIS using costume scripts written in python.

You don't need to install python separately, if you install QGIS it comes with its own python set by default.

From the "Plugin" menu select "Python Console" to open the Python Console interface where yo can type and run python scripts in QGIS. You can also do this by clicking on the "Python Console" icon from the tools bar.



To print a simple "Hello world!" script, use the "Interactive Console" at the bottom as follow;-

Type print "Hello world!" on the "Interactive Console" and press "Enter" key or click "Run Command" button to display the result as seen below.



This is how to start "Python Console" and run python script in QGIS.

Thanks for reading.

No comments:

Post a Comment