Learn R Programming

raptr (version 1.0.1)

amount.target: Amount targets

Description

This function sets or returns the target amounts for each species.

Usage

amount.target(x, species)

amount.target(x, species) <- value

# S3 method for RapData amount.target(x, species = NULL)

# S3 method for RapData amount.target(x, species = NULL) <- value

# S3 method for RapUnsolOrSol amount.target(x, species = NULL)

# S3 method for RapUnsolOrSol amount.target(x, species = NULL) <- value

Value

numeric vector.

Arguments

x

RapData(), RapUnsolved(), or RapSolved() object.

species

NULL for all species or integer indicating species.

value

numeric new target.

See Also

RapData(), RapResults(), RapSolved().

Examples

Run this code
if (FALSE) {
# load data
data(sim_rs)

# extract amount targets for all species
amount.target(sim_rs)

# set amount targets for all species
amount.target(sim_rs) <- 0.1

# extract amount targets for first species
amount.target(sim_rs, 1)

# set amount targets for for first species
amount.target(sim_rs, 1) <- 0.5
}

Run the code above in your browser using DataLab