Вы находитесь на странице: 1из 9

A tutorial for using CLUZ with GQIS

Exercise 1: An introduction to CLUZ


CLUZ is a QGIS plugin that lets the user design conservation landscapes based on the principles of
systematic conservation planning. In this exercise you will first download the relevant files and save the
QGIS project file that you will use in this exercise.

In the second section you will view the CLUZ files and you will use these in the third section to carry out
on-screen conservation planning to meet the required conservation targets. In the fourth section you will
see how Marxan can be used to produce more efficient conservation plans and the fifth section
describes further work for exploring CLUZ and Marxan.

Section 1a – Setting up Marxan, CLUZ and QGIS


1) Obtain Marxan from the University of Queensland website http://www.uq.edu.au/marxan/ by
registering and downloading the Version 2.43 zip file. For these exercises you will use either
Marxan.exe or Marxan_x64.exe depending on whether you have a 32-bit or 64-bit computer
processor. YOU SHOULD PLACE MARXAN IN A FOLDER WHERE YOU HAVE PERMISSION TO
WRITE FILES. As part of running Marxan, CLUZ needs to update the Marxan input file and so
needs access to write in the folder where Marxan is located.

2) CLUZ requires version 2.4 or later of QGIS so make sure you have a suitable version installed.
Open QGIS, in the Plugins menu select Manage and Install plugins… dialog box and scroll down
the list of plugins until you reach CLUZ. Select CLUZ in the list and click on Install plugin. Close
the dialog box. You should see the CLUZ menu and six buttons have been added to the toolbar.

3) Obtain the CLUZ tutorial files from http://anotherbobsmith.wordpress.com/software/cluz/ by


downloading the cluz_ex1.zip file (your Internet browser may warn you about downloading zip files
but these CLUZ files are safe). Unzip the files and save the cluz_ex1 folder on your computer in a
suitable location.

Section 1b – Viewing the CLUZ files


CLUZ provides a set of tools that allow users to identify a portfolio of planning units that, when
combined, meet specified conservation targets. To do this CLUZ uses three files that describe the
planning units, the distributions of the conservation features and the conservation target for each
conservation feature.

A fourth file describes the location of these files and sets where the Marxan input and output data are
stored. In this section you will view and familiarise yourself with these four files.

1) In QGIS go to the CLUZ menu and choose View and edit CLUZ setup file. This will open the
File Settings dialog Box.

2) The File Settings dialog box will appear and you can use this to set the location of each specified
file and folder. Start by clicking on the Browse button next to the Marxan location input. Navigate
to the folder where you saved Marxan and choose Marxan.exe (if you have a 32-bit computer
processor) or Marxan_x64.exe (if you have a 32-bit computer processor)

3) Repeat the process to set the paths for the CLUZ data contained in the cluz_ex1 folder that you
extracted from the zip file. Set the input directory as \cluz_ex1\input, the output directory as
\cluz_ex1\output, the planning unit layer as \cluz_ex1\planning units.shp and the target table as
\cluz_ex1\target.csv. Set the Decimal places for numbers in Abundance and Target table as 3. Click
on the Save As button and save the file as ex1.clz in the cluz_ex1 folder.

Tutorial for CLUZ with QGIS version 2.0 (20/2/2016) 1


This should add the planning unit shapefile to the Table of Contents and display it. Click on the Close
button.
4) You should see that the theme consists of a number of hexagonal planning units (there are 4661 in
all) that are coloured according to their conservation status (Conserved, Earmarked, Available
and Excluded). In the northeast of the study region there should be a patch of Conserved units
and two smaller patches of Excluded units should be located below the Conserved units.

5) Right-click on the name Planning units in the Table of Contents and select Open Attribute Table
from the drop-down menu. You should see that the table contains four fields.

The Unit_ID field contains a unique numerical ID value for each planning unit, the Area field gives
the area of each unit in hectares. The Cost field gives the cost of including the unit in any
conservation portfolio (which in this case is assumed to be the same as the area value) and the
Status field that describes the conservation status of each unit.

6) Close the Planning units attribute table and click on the Open Target Table button to display a
table containing 8 fields. The Id field lists the numeric ID of each conservation feature and the
Name field in the target table gives the full name of the feature. The Target field gives the required
amount of each feature that should be represented in the final portfolio and the Spf field lists the
species penalty factor (this will be explained in more detail later).

The Conserved field lists the amount of each feature that is found in units that have Conserved or
Earmarked status. The Total field lists the total amount of each feature in all of the units and the
Pc_target shows the percentage of the target that has been reached, based on the Conserved
and Target fields. The Type field is not a required CLUZ field but it can be used to distinguish
between different types of conservation feature when setting the target values.

Notice the two conservation features with a type value of 0. These are landcover types with little or
no conservation value and so their target values have been set as 0. This means that only 19 of the
conservation features have targets set and the value of –1 will appear in the Pc_target field for
those features with a target value of 0.

Notice also that values in the Pc_target field are colour coded. They are red if the target has not
been met (value is less than 100%), green if the target has been met and grey if the target is 0.

7) Close the target table to return to the main QGIS window. The data listing how much of each
conservation feature is found in each planning unit is stored in the Marxan file puvspr2.dat which is
in the input folder. To view these data click on the Open Abundance Table button and you
should see a dialog box listing the names and ID values of the 21 conservation features. Select all
of these features and click on the OK button to produce the abundance table.

The first field is identical to the Unit_id field in the unit layer table, whereas each of the other fields
contains data on the abundance of a particular conservation feature found in each planning unit.
Each of the fields containing data on a particular feature has the column name “F_” followed by
their id value. Close the table to return to the main QGIS window.

Tutorial for CLUZ with QGIS version 2.0 (20/2/2016) 2


Section 1c - On-screen conservation planning
CLUZ has been designed to act as an interface for Marxan but it can also be used on its own to carry
out on-screen conservation planning. It lets the user change the conservation status of the different
planning units and investigate how this affects the number of targets met by the conservation portfolio
of units.

It also lets the user refine portfolios identified by Marxan to incorporate expert opinion that cannot be
inputted as Marxan data. The main set of tools for on-screen planning is found on the Change Status
panel, so this next section explores these features in more detail.

The status of each planning unit can either be set as Conserved, Earmarked, Available or Excluded.
Conserved units are those that fall within an existing protected area (PA) and so already form part of
the conservation portfolio. Excluded units are those that are unsuitable for ecological, political or other
reasons and so will not form part of any portfolio.

This means that most of the conservation planning that you will do involves changing the status of
Available and Earmarked units. Available units are those that could form part of a portfolio but are not
presently selected. Earmarked units are those that have been earmarked for conservation, ie they do
not form part of an existing PA but they are part of the conservation portfolio that is being investigated.

1) Click on the Change planning unit status button . You will use this together with the QGIS
Select Features tool to select the planning units you want and then change their status.

You will also see that the panel shows the number of abundance targets that have been met by the
present portfolio, based on the values in the Target and Conserved fields in the target table. In this
case, it should show that 5 of the 19 targets have been met.

2) CLUZ assumes that you will only want to set the status of Conserved and Excluded units at the
beginning of the process and that these units are likely to remain unchanged during the rest of the
on-screen planning process. This is why the option to set the required status as Conserved or
Excluded is not automatically shown when you open the Change Status panel.

If you want to set the status of selected units to Conserved or Excluded, or if you want to change
the status of Conserved or Excluded units, then you need to click on the Allow changes in
conserved and excluded status checkbox . You will NOT need to do this for this tutorial.

3) You are now ready to use the Change Status panel to carry out on-screen conservation planning.
Move the Change Status panel so it is not covering the planning unit layer and make sure the
Earmarked Radio button is selected . Then click on the Select features tool
and from the drop-down menu, choose Select Features by Polygon

Move the mouse icon to the middle of the block of Conserved units and left-click once to start on-
screen digitising a polygon. Then move the mouse icon and keep on left-clicking to set the
boundaries of a polygon that should include approximately 10% of the planning units in the region
to the south of the Conserved units. Once you have finished setting the polygon boundary, right
click to finish and the units that fall within the polygon you have specified should be selected and
turn bright yellow.

4) Now click on the Change button in the Change status panel


and notice how the selected Available units have been
changed to have Earmarked status (as shown in the picture
on the right). Also notice that any Conserved or Excluded
units remain unchanged. Check to see whether including the
selected units in the conservation portfolio has increased the
number of abundance targets that have been met by reading
the text above the Change button.

Tutorial for CLUZ with QGIS version 2.0 (20/2/2016) 3


5) Close the Change Status panel and click on the Open Target Table button . By looking at the
Pc_target field you can identify which conservation features remain under-represented in the
portfolio. In particular, you should be able to see that none of the montane landcover types (ID
values 1-6) have any protection.

You will now aim to meet the targets for all of the montane landcover types by adding some
Earmarked units in the west of the planning region. Do this by first closing the target table and in
the CLUZ menu choose Display distribution of conservation features. Select 1 –
Montane_aquatic from the list in the dialog box and click on OK.

6) CLUZ will produce distribution maps for the selected features based on the data in the abundance
table. Make the new layer visible so that you can see where the montane aquatic landcover type is
located. Now open the Change Status panel again and use the Select features tool to
select some units that include some of this landcover type. Make sure the planning unit theme is
selected (highlighted in blue in the table of contents).

Change the status of the selected units to Earmarked and check the target table again to
identify whether the feature need further protection. Once you have reached the target for a
particular feature then remove the Montane_aquatic distribution layer from the QGIS window.

Repeat this process for the other landcover types that have not met their targets. That is, display
the distribution maps of the under-represented landcover types, change the status of planning units
that contain these types to Earmarked and then remove the associated distribution layer once their
target have been met.

7) The portfolio you have selected may contain more of each feature than is needed to meet the
specified targets. These targets have been set to ensure the long-term conservation of each
feature, and so exceeding these targets fails to balance the requirements of conservation with
those of other land-uses.

To reduce this problem, identify which features are over-represented by viewing the target table .
Then use the Change Status panel, together with the Display distribution of conservation
features option to change the status of the surplus units from Earmarked to Available.

Select Undo on the Change Status panel if changing the status of a set of units to Available
reduces the number of abundance targets that have been met.

8) Once you are happy with your final portfolio, in the QGIS Project menu select Save as Image…
and save the results as a file named onscreen.bmp in the cluz_ex1 folder.

Section 1d – Using Marxan to select conservation portfolios


In the previous section you will have seen that it is possible to use on-screen techniques to design a
conservation portfolio. However, the results of these exercises tend to be inefficient and are more
difficult to produce when dealing with a large number of targets. In this section you will use Marxan to
produce a quicker and more efficient solution.

1) Open the Change Status panel and use the Select Features tool to select all of the units.
Change their status to Available. This should produce the original portfolio showing only the patch
of Conserved units and the two patches of Excluded units. Remove any other layers so that only
the planning unit layer is present and close the Change Status panel.

2) Marxan only uses specifically formatted text files to input the data it needs, so the first step is to
convert the CLUZ data into Marxan format. Go to the CLUZ menu, choose the Create Marxan
input files option and click on all the checkboxes, so that you will produce all three of the additional
files used by Marxan.

Selecting the Boundary file (bound.dat) checkbox gives you the option to select the Include
planning region boundaries option. DO NOT click this Include planning region boundaries

Tutorial for CLUZ with QGIS version 2.0 (20/2/2016) 4


checkbox, so that the edges of units that are not shared (ie form the boundary of the study region)
are not included in the boundary.dat file. External edges should generally be excluded if they
make up a natural boundary, such as a coastline.

Click on OK to produce all three of the additional files needed by Marxan. These will be stored in
the input folder you specified in the setup file, together with the puvspr2.dat file that was already
stored in the input folder.

You are now ready to run Marxan. Remember that Marxan will only use data from the text files
you have just created. If you change any of the CLUZ data you must update these text files by
repeating the process above before running Marxan.

3) In the CLUZ menu choose Launch Marxan. Under Standard options in the dialog box, you will
see that the number of iterations has been set as 1000000 and the number of runs as 10.
Increasing the number of iterations and runs will generally improve the efficiency of the portfolios
that Marxan identifies but also increases processing time.

In this tutorial you will use these default values to reduce the time Marxan spends processing the
data. Set output1 as the Output file name and leave the Include boundary cost (BLM) and
Produce extra Marxan outputs checkboxes unchecked . Selecting the Produce extra Marxan
outputs option saves files describing the results from each run in the output folder, which are not
needed for this exercise.

Click on Start Marxan and the Marxan dialog box should appear. The Marxan dialog box will show
that the data are being inputted and will then give details on each of the 10 runs. Once it has
finished it will display “The End. Press return to exit”. Follow these instructions by pressing the
return button on the keyboard.

4) Return to QGIS and two new layers should be displayed. The Best layer (output1) shows a
portfolio of units in magenta. This portfolio was the most efficient of the 10 solutions produced by
Marxan. Make the Best layer (output1) invisible and then inspect the SF_Score (output1) layer.

The summed layer shows the number of times that each unit was selected to be part of one of the
10 portfolios. This is similar to an irreplaceability score, with the most important units being included
in the largest number of portfolios.

Click on the Open Marxan results table button to view the text file that Marxan has saved in
the \output folder. This lists each feature, its target and whether the target was met. In particular,
Target met states yes or no and MPM shows the Minimum Proportion Met of the target, i.e. if the
MPM is less than 0 then the target has not been met.

5) Make the Best layer active and open the Attribute Table . Note that two fields have been
added to the table. The Best field contains the word Selected for the units that were included in the
most efficient portfolio and SF_Score gives the irreplaceability score for each unit. The information
in these fields will be overwritten every time you run Marxan.

Close the table and make the SF_Score (output1) invisible and the Best layer visible, so that the
planning units layer and the best portfolio are displayed. In the QGIS Project menu select Save as
Image… and save the results as a file named marxan_blm0.bmp in the cluz_ex1 folder.

6) The portfolio identified by Marxan may be efficient but it is very fragmented and would be
ecologically unviable and expensive to manage. Marxan can overcome this problem by including a
boundary cost that favours the identification of portfolios that form patches of planning units. Do this
by choosing Launch Marxan from the CLUZ menu again but this time, click the Include boundary
cost (BLM) on and set a value of 0.5.

7) The new layers Best layer (output2) and SF_Score (output2) should be displayed and the
portfolios they describe should form patches of units. Once again, click on the Open Marxan

Tutorial for CLUZ with QGIS version 2.0 (20/2/2016) 5


results table button to see whether all the targets have been met and then in the QGIS Project
menu select Save as Image… and save the results as a file named marxan_blm1.bmp in the
cluz_ex1 folder.

8) Compare the two images you have produced in terms of efficiency (number of planning units
selected) and fragmentation (number of patches).

Section 1e – Further work


You have now finished this exercise. If you want to explore the data further then try the following:
 Change the targets in the target table and use CLUZ and Marxan to produce new portfolios.
 Investigate the effects of using different boundary length modifier values in Marxan.
 Choose four units at random and set them as having Conserved status. Now update the
Marxan pu.dat file using the Create Marxan input files option and run Marxan to investigate
how the spatial patterns of the resultant portfolios are affected.

Tutorial for CLUZ with QGIS version 2.0 (20/2/2016) 6


Exercise 2: Producing the CLUZ files
This exercise shows how to produce the CLUZ files that you used in exercise 1. The first part shows
how to create these files and the second and third parts show how to update these files based on the
available abundance and conservation status data.

Part 2a: Creating the planning unit shapefile, target and abundance data
In this section you will produce the blank files that CLUZ needs to operate.

1) Obtain the CLUZ tutorial files from http://anotherbobsmith.wordpress.com/software/cluz/ by


downloading the cluz_ex2.zip file (your Internet browser may warn you about downloading zip files
but these CLUZ files are safe). Unzip the files and save the cluz_ex2 folder on your computer in a
suitable location.

2) Add the nature reserve and hexagons layers from the cluz_ex2 folder to the View and display
them. You will see the nature reserve layer shows the boundary of a protected area and the
hexagons layer shows a number of 25 ha hexagons that have been clipped the planning region
boundary. Hexagonal planning units are often used in conservation planning exercises but planning
units can be any shape. Remove the two shapefiles from the View.

Now add the planning units layer from the \cluz_ex2 folder to the View. This was produced by
using the Union function in QGIS to combine the nature reserve and hexagons layers. Notice how
each planning unit is a hexagon or a section of a hexagon if it crosses the nature reserve or
planning region boundary. Make the planning units layer active and click on Open Attribute Table
button and notice that the table only contains fields called Name and Region. Close the table
and remove the planning units layer from the View.

3) Next you will create the CLUZ files by modifying the planning unit layer and creating the
puvspr2.dat and target files. In the CLUZ menu choose Create initial CLUZ files. Click on the
Select shapefile Browse button and select the planning units layer. Set the Area conversion
factor as 10000 as this will convert the Area values from m2 to hectares. Click on the Set cost
layer as equal to planning unit area. Set the input folder where the puvspr2.dat file will be stored
as \cluz_ex2\input and specify that the target table should be named targets.csv and saved in the
\cluz_ex2 folder. CLUZ will tell you when the files have been produced and you can close the Task
completed message at the top of the View.

Once the process has finished, click on the Open Attribute Table button again. Notice that
CLUZ has added fields named Unit_ID, Area, Cost and Status. You will see that the unique
Unit_ID value is set as the row number and that the Cost value is the same as the Area value
(which should be 25 ha for the complete hexagons).

4) You have now created the files that CLUZ needs to undertake conservation planning. The
puvspr2.dat and targets.csv files are blank but contain the required fields. In the later steps you will
modify these tables but you must first create a CLUZ setup file. Do this by choosing View and
edit CLUZ setup file from the CLUZ menu.

Repeat the process you learnt about in Exercise 1. Click on the Browse buttons to set the different
input parameters. These should be identical to those shown in the figure associated with Exercise
1b part 3, except the specified folder for the CLUZ files should be \cluz_ex2 not \cluz_ex1. Use the
Save As button to save the setup files as exercise2.clz in the \cluz_ex2 folder.

Now click on the Open Target Table button and note that the table does not contain any data
yet. Close the table to return to the View.

Part 2b: Updating the status of the planning units


In this section you will update the Status information in the planning units layer. In particular, you will
specify that planning units near to two proposed economic “growth points” should be Excluded and
planning units within the nature reserve should be set as Conserved.

Tutorial for CLUZ with QGIS version 2.0 (20/2/2016) 7


5) From the \cluz_ex2 folder add the layer called growth_points.shp to the View. You will exclude all
planning units that are within 2 km of these points, so the first step is to produce a layer showing
the area that falls within this distance. In the QGIS menu Vector > Geoprocessing Tools choose
. Set the Input vector layer as the growth points layer, the Buffer distance as 2000,
the Segments to approximate as 50 and save the shapefile growth_points_buffer into the
\cluz_ex2 folder. Make sure the final result is added to the View (also called the Canvas).

Now got to Vector > Spatial Query > (if it is not visible you will have
to install it as a plugin). Specify Select source feature from as Planning units,
Reference features of as growth_points_buffer and Where the feature is
Within. NB You will need to specify the growth_points_buffer layer first before
selecting Where the feature to produce a list that includes the Within option. Now
click on the Apply button and you should see that 73 planning units are selected.
Close the dialog box and turn off the growth_points_buffer layer to see the
selected planning units.

6) Now click on the open the Change Status Panel button and click on the Allow
changes to Conserved and Excluded status tick box . This will display the
Conserved and Excluded radio buttons, so select the Excluded radio button and
click on the Change button.

The selected units should now be coloured in purple to show they have Excluded status and will
not be included in any portfolio selected by Marxan. Close the Change Status panel and remove
the growth_point and growth_point_buffer theme from the View.

7) The next step is to set the status of the Conserved units and this involves identifying the planning
units that fall within the nature reserve. Click on the Select features using an expression button
on the QGIS menu bar . In the Expression box type "NAME" = 'Ithemba' and click on the Select
button at the bottom of the dialog box. This should have selected all the planning units that belong
to the nature reserve, which is called Ithemba and named in the original nature reserve layer.

Now click on the Open Change Status Panel button again and click on the Allow Changes to
Conserved and Excluded status tick box . This time select the Conserved radio button
and click on the Change button.

Part 2c: Adding abundance data and updating the target table
You can use CLUZ to import data on the distribution of your conservation features, either by extracting
the data from shapefiles or using data that has been produced through other methods.

8) Data on the distributions of 18 landcover types are stored in a separate csv file, which was
produced from a landcover map. Open the file named landcover.csv in the \cluz_ex2 folder in
Excel and you should see the first field contains the planning unit ID values and the other field
names include a number, which represents the conservation feature ID values. Each cell in these
2
other fields gives the area in m of the associated feature in the planning unit.

You will now add these data by going to the CLUZ menu and choosing Import fields from table
to Marxan abundance file. Use the Browse button to select the landcover.csv file from the
\cluz_ex2 folder and set that the Layer ID Field name is the one called Value. Turn on the
option and specify the Area conversion vale as 10000 to convert values from
m2 to hectares.

9) Check the data have been imported correctly by clicking on the Open abundance table button
and selecting all the features. Close the abundance table, open the target table and notice that
18 new rows have been added to the table and the numerical identifier of the added features has
been added to the Id field. The Name, Type, Target and Spf values are blank but you will fill those
in later.

Tutorial for CLUZ with QGIS version 2.0 (20/2/2016) 8


10) CLUZ can also be used to extract distribution data from shapefiles and to demonstrate this add the
theme called cycad.shp from the \cluz_ex2 folder. The cycad theme shows the distribution of two
species, one of which is found in two areas in the northwest and southwest.

Make the theme active and click on the Open Attribute Table button and notice that the table
contains a field called ID containing the ID values 105 and 107. All themes you wish to incorporate
must contain a numeric field that contains the unique identifiers for each conservation feature.

Close the table and in the CLUZ menu choose the module Convert polyline or polygon themes
to Marxan abundance data. Select cycad.shp as the theme you want to use, leave the default
value that the Layer ID field name is ID, turn on the button and set the
value as 10000 to convert values from m2 to hectares.

11) Now you will add data on the presence of vulture nests using the Import fields from table to
Marxan abundance file option. The file nest_data.csv contains a count of the number of nests per
planning unit so use the Browse button to specify the file and set the Layer ID field name as
Unit_ID. Choose the because this is count data
and does not need to be converted. Then click on OK.

12) Click on the Open target table button and you should see the new features have been added
and the cycad species have ID values of 105 and 107, whilst the vulture nest ID value is 156. You
now need to add the relevant data on each of the 21 conservation features and you will do this in
Excel. Open the targets.csv file that you created and the feature_details.csv file that are in the
/cluz_ex2 folder.

To set the targets for the landcover types, you will use a system where anthropogenic types (Type
0) are given a target of 0%, common natural landcover types (Type 1) are given a target of 20% of
their total and endemic or threatened landcover types are given a target of 40% of their total area.
So in Excel specify the target in cell D2 as =0.2*C2*G2 and then drag down the formula for the rest
of the landcover target values.

For the species data set the targets as specified below.


ID Name Target
105 F. splendens 2000
107 A. gigantica 2000
156 Vulture nest 20

Now save the data in your targets.csv file by clicking on the Save button and selecting Yes. Close
the file in Excel and in CLUZ click on the Open target table button . You should now see the
updated information that you added and the PC_target field automatically updates to show how
well the targets have been met.

YOU HAVE NOW COMPLETED THIS EXERCISE AND THE TABLES YOU HAVE PRODUCED
SHOULD BE IDENTICAL TO THOSE PROVIDED IN EXERCISE 1.

Tutorial for CLUZ with QGIS version 2.0 (20/2/2016) 9

Вам также может понравиться