Skip to contents

Overview

Overview of the package.

prioritizr prioritizr-package
prioritizr: Systematic Conservation Prioritization in R

Create and solve problems

Functions for creating new problems and solving them.

problem()
Conservation planning problem
solve(<ConservationProblem>)
Solve
zones()
Management zones

Data

Simulated datasets distributed with the package.

Objectives

Functions for adding an objective to a problem.

objectives
Add an objective
add_max_cover_objective()
Add maximum coverage objective
add_max_features_objective()
Add maximum feature representation objective
add_max_phylo_div_objective()
Add maximum phylogenetic diversity objective
add_max_phylo_end_objective()
Add maximum phylogenetic endemism objective
add_max_utility_objective()
Add maximum utility objective
add_min_largest_shortfall_objective()
Add minimum largest shortfall objective
add_min_set_objective()
Add minimum set objective
add_min_shortfall_objective()
Add minimum shortfall objective

Targets

Functions for adding targets to a problem.

targets
Add representation targets
add_absolute_targets()
Add absolute targets
add_loglinear_targets()
Add targets using log-linear scaling
add_manual_targets()
Add manual targets
add_relative_targets()
Add relative targets

Constraints

Functions for adding constraints to a problem.

constraints
Conservation problem constraints
add_contiguity_constraints(<ConservationProblem>,<ANY>,<ANY>) add_contiguity_constraints(<ConservationProblem>,<ANY>,<data.frame>) add_contiguity_constraints(<ConservationProblem>,<ANY>,<matrix>)
Add contiguity constraints
add_feature_contiguity_constraints(<ConservationProblem>,<ANY>,<data.frame>) add_feature_contiguity_constraints(<ConservationProblem>,<ANY>,<matrix>) add_feature_contiguity_constraints(<ConservationProblem>,<ANY>,<ANY>)
Add feature contiguity constraints
add_linear_constraints(<ConservationProblem>,<ANY>,<ANY>,<character>) add_linear_constraints(<ConservationProblem>,<ANY>,<ANY>,<numeric>) add_linear_constraints(<ConservationProblem>,<ANY>,<ANY>,<matrix>) add_linear_constraints(<ConservationProblem>,<ANY>,<ANY>,<Matrix>) add_linear_constraints(<ConservationProblem>,<ANY>,<ANY>,<Raster>) add_linear_constraints(<ConservationProblem>,<ANY>,<ANY>,<SpatRaster>) add_linear_constraints(<ConservationProblem>,<ANY>,<ANY>,<dgCMatrix>)
Add linear constraints
add_locked_in_constraints()
Add locked in constraints
add_locked_out_constraints()
Add locked out constraints
add_mandatory_allocation_constraints()
Add mandatory allocation constraints
add_manual_bounded_constraints()
Add manually specified bound constraints
add_manual_locked_constraints()
Add manually specified locked constraints
add_neighbor_constraints(<ConservationProblem>,<ANY>,<ANY>,<ANY>,<ANY>) add_neighbor_constraints(<ConservationProblem>,<ANY>,<ANY>,<ANY>,<data.frame>) add_neighbor_constraints(<ConservationProblem>,<ANY>,<ANY>,<ANY>,<matrix>) add_neighbor_constraints(<ConservationProblem>,<ANY>,<ANY>,<ANY>,<array>)
Add neighbor constraints

Penalties

Functions for adding penalties to a problem.

penalties
Add a penalty
add_asym_connectivity_penalties(<ConservationProblem>,<ANY>,<ANY>,<matrix>) add_asym_connectivity_penalties(<ConservationProblem>,<ANY>,<ANY>,<Matrix>) add_asym_connectivity_penalties(<ConservationProblem>,<ANY>,<ANY>,<data.frame>) add_asym_connectivity_penalties(<ConservationProblem>,<ANY>,<ANY>,<dgCMatrix>) add_asym_connectivity_penalties(<ConservationProblem>,<ANY>,<ANY>,<array>)
Add asymmetric connectivity penalties
add_boundary_penalties(<ConservationProblem>,<ANY>,<ANY>,<ANY>,<data.frame>) add_boundary_penalties(<ConservationProblem>,<ANY>,<ANY>,<ANY>,<matrix>) add_boundary_penalties(<ConservationProblem>,<ANY>,<ANY>,<ANY>,<ANY>)
Add boundary penalties
add_connectivity_penalties(<ConservationProblem>,<ANY>,<ANY>,<matrix>) add_connectivity_penalties(<ConservationProblem>,<ANY>,<ANY>,<Matrix>) add_connectivity_penalties(<ConservationProblem>,<ANY>,<ANY>,<data.frame>) add_connectivity_penalties(<ConservationProblem>,<ANY>,<ANY>,<dgCMatrix>) add_connectivity_penalties(<ConservationProblem>,<ANY>,<ANY>,<array>)
Add connectivity penalties
add_feature_weights(<ConservationProblem>,<numeric>) add_feature_weights(<ConservationProblem>,<matrix>)
Add feature weights
add_linear_penalties(<ConservationProblem>,<ANY>,<character>) add_linear_penalties(<ConservationProblem>,<ANY>,<numeric>) add_linear_penalties(<ConservationProblem>,<ANY>,<matrix>) add_linear_penalties(<ConservationProblem>,<ANY>,<Matrix>) add_linear_penalties(<ConservationProblem>,<ANY>,<Raster>) add_linear_penalties(<ConservationProblem>,<ANY>,<SpatRaster>) add_linear_penalties(<ConservationProblem>,<ANY>,<dgCMatrix>)
Add linear penalties

Decisions

Functions for specifying the type of decisions in a problem.

decisions
Add decision types
add_binary_decisions()
Add binary decisions
add_proportion_decisions()
Add proportion decisions
add_semicontinuous_decisions()
Add semi-continuous decisions

Solvers

Functions for specifying how a problem should be solved.

solvers
Add solvers
add_cbc_solver()
Add a CBC solver
add_cplex_solver()
Add a CPLEX solver
add_default_solver()
Add default solver
add_gurobi_solver()
Add a Gurobi solver
add_highs_solver()
Add a HiGHS solver
add_lpsymphony_solver()
Add a SYMPHONY solver with lpsymphony
add_rsymphony_solver()
Add a SYMPHONY solver with Rsymphony

Portfolios

Functions for generating a portfolio of solutions.

portfolios
Add portfolios
add_cuts_portfolio()
Add Bender's cuts portfolio
add_default_portfolio()
Add a default portfolio
add_extra_portfolio()
Add an extra portfolio
add_gap_portfolio()
Add a gap portfolio
add_shuffle_portfolio()
Add a shuffle portfolio
add_top_portfolio()
Add a top portfolio

Summary statistics

Functions for summarizing the performance of solutions.

Importance

Functions for calculating importance scores for a solution.

importance irreplaceability
Evaluate solution importance
eval_ferrier_importance()
Evaluate solution importance using Ferrier scores
eval_rare_richness_importance()
Evaluate solution importance using rarity weighted richness scores
eval_replacement_importance()
Evaluate solution importance using replacement cost scores

Data simulation

Functions for simulating new datasets.

simulate_cost()
Simulate cost data
simulate_data()
Simulate data
simulate_species()
Simulate species habitat suitability data

Geoprocessing

Functions for manipulating spatial datasets.

fast_extract()
Fast extract
intersecting_units()
Find intersecting units

Marxan functions

Functions for importing and converting Marxan data.

marxan_problem()
Marxan conservation problem
marxan_boundary_data_to_matrix()
Convert Marxan boundary data to matrix format
marxan_connectivity_data_to_matrix()
Convert Marxan connectivity data to matrix format

Matrix functions

Functions for creating matrices that are used in conservation planning problems.

adjacency_matrix()
Adjacency matrix
boundary_matrix()
Boundary matrix
branch_matrix()
Branch matrix
connectivity_matrix()
Connectivity matrix
proximity_matrix()
Proximity matrix
rij_matrix()
Feature by planning unit matrix
rescale_matrix()
Rescale a matrix

Processing multi-zone data

Functions for manipulating data that pertain to multiple zones.

category_layer()
Category layer
category_vector()
Category vector
binary_stack()
Binary stack

Problem manipulation functions

Functions for working with problems.

compile()
Compile a problem
feature_abundances()
Feature abundances
feature_names()
Feature names
number_of_features()
Number of features
number_of_planning_units()
Number of planning units
number_of_total_units()
Number of total units
number_of_zones()
Number of zones
presolve_check()
Presolve check
run_calculations()
Run calculations
write_problem()
Write problem
zone_names()
Zone names

Class definitions and methods

Documentation for internal classes and associated functions.

Miscellaneous functions

Assorted functions distributed with the package.

Deprecated functions

Documentation for functions that are no longer available.