extract_slope_params: This function extracts slope parameters for the connection...

Description Usage Arguments Value Examples

View source: R/extract_slope_params.R

Description

This function extracts slope parameters for the connection between two lakes from the requisite database.

Usage

1
2
extract_slope_params(parameters_of_interest, connectivity, con,
  include.length = FALSE, db.schema = "temporary_sweden_connectivity")

Arguments

parameters_of_interest

A vector containing the names of the slope parameters you wish to extract. These can be extracted using the code found in the examples.

connectivity

A matrix which should include the upstream and downstream lake you wish to evalutate and the presence or absence of your target fish in the upstream lake.

con

The connection parameters set to connect to your database

Value

The connectivity table with slope parameters adjoined.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
# Extract parameters using the following code:
parameters <- colnames(tbl(database_folder, "example_connectivity_matrix") %>%
head() %>%
 collect())

# Check parameters you need
names(parameters)

parameters_of_interest <- parameters[12:15]

slope_table <- extract_slope_params(parameters_of_interest, connectivity)

samaperrin/analyseslope documentation built on Jan. 8, 2020, 9:19 p.m.