byGridCell_ScalarOps: Perform a scalar operation on grid cell values

View source: R/byGridCell_ScalarOps.R

byGridCell_ScalarOpsR Documentation

Perform a scalar operation on grid cell values

Description

Function to perform a scalar operation on grid cell values.

Usage

byGridCell_ScalarOps(
  dfr1,
  op = "+",
  scalar = 0,
  cols = c("unsuccessful_indivs", "successful_indivs", "total_indivs",
    "unsuccessful_abundance", "successful_abundance", "total_abundance")
)

Arguments

dfr1

- dataframe with results by grid cell

op

- operation to perform ("+","-","*","/","\","^","log","sqrt")

scalar

- scalar value to use

cols

- dataframe column names to scale

Details

Columns in datafram not specified in cols are returned unchanged. "/" performs grid/scalar whereas "\" performs scalar/grid.

Value

dataframe with results in requested columns.


wStockhausen/rDisMELS documentation built on March 27, 2022, 1 a.m.