natcap.invest.fisheries.fisheries_hst

The Fisheries Habitat Scenario Tool module contains the high-level code for generating a new Population Parameters CSV File based on habitat area change and the dependencies that particular classes of the given species have on particular habitats.

natcap.invest.fisheries.fisheries_hst.convert_survival_matrix(vars_dict)

Creates a new survival matrix based on the information provided by the user related to habitat area changes and class-level dependencies on those habitats.

Parameters

vars_dict (dictionary) – see fisheries_preprocessor_io.fetch_args for example

Returns

modified vars_dict with new Survival matrix

accessible using the key ‘Surv_nat_xsa_mod’ with element values that exist between [0,1]

Return type

vars_dict (dictionary)

Example Returns:

ret = {
    # Other Variables...

    'Surv_nat_xsa_mod': np.ndarray([...])
}
natcap.invest.fisheries.fisheries_hst.execute(args)

Fisheries: Habitat Scenario Tool.

The Fisheries Habitat Scenario Tool generates a new Population Parameters CSV File with modified survival attributes across classes and regions based on habitat area changes and class-level dependencies on those habitats.

args[‘workspace_dir’] (str): location into which the resultant

modified Population Parameters CSV file should be placed.

args[‘sexsp’] (str): specifies whether or not the age and stage

classes are distinguished by sex. Options: ‘Yes’ or ‘No’

args[‘population_csv_path’] (str): location of the population

parameters csv file. This file contains all age and stage specific parameters.

args[‘habitat_chg_csv_path’] (str): location of the habitat change

parameters csv file. This file contains habitat area change information.

args[‘habitat_dep_csv_path’] (str): location of the habitat dependency

parameters csv file. This file contains habitat-class dependency information.

args[‘gamma’] (float): describes the relationship between a change

in habitat area and a change in survival of life stages dependent on that habitat

Returns

None

Example Args:

args = {
    'workspace_dir': 'path/to/workspace_dir/',
    'sexsp': 'Yes',
    'population_csv_path': 'path/to/csv',
    'habitat_chg_csv_path': 'path/to/csv',
    'habitat_dep_csv_path': 'path/to/csv',
    'gamma': 0.5,
}

Note

  • Modified Population Parameters CSV File saved to ‘workspace_dir/output/’