aggregateObservationFlag: This function performs aggregation of flags

Description Usage Arguments Details Value See Also Examples

Description

The aggregation is based on the weight of the flag as designated by the table. Official sources have high weight while data from unreliable sources have low weight.

Usage

1

Arguments

...

Vectors of flags, each of the same length. See details.

flagTable

The table which maps the relationship between the flag and its information weight. see dataflagWeightTable

Details

This function works in a similar way to base::sum. The first argument is ..., and this allows the user to pass multiple vectors of flags which should all be aggregated.

Value

A character vector containing the aggregated flags.

See Also

sum

Examples

1
2
3
4
5
6
7
aggregateObservationFlag("T", "E")
# Passing multiple flags aggregates them all together:
aggregateObservationFlag("", "T", "E", "I", "M")
# You can also pass vectors:
aggregateObservationFlag(c("T", "T"), c("M", ""))
# And more than 2 vectors:
aggregateObservationFlag(c("T", "T"), c("M", ""), c("I", ""))

SWS-Methodology/faoswsFlag documentation built on May 9, 2019, 11:47 a.m.