Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

doublebracket-set

Add or change column of horizon or site data in a SoilProfileCollection


Description

Add or change the data from a column accessed by name. Column names other than profile ID are not shared between site and horizons. The benefit of using double bracket setter over $ is that name can be calculated, whereas with $, it must be known a priori and hard coded.

When using the double bracket setter the length of input and output matching either the number of sites or number of horizons is used to determine which slot new columns are assigned to.

Usage

## S4 replacement method for signature 'SoilProfileCollection,ANY,ANY'
x[[i]] <- value

Arguments

x

a SoilProfileCollection

i

an expression resolving to a single column name in site or horizon table-

value

New value to replace – unit length or equal in length to number of sites or horizons in the collection.


aqp

Algorithms for Quantitative Pedology

v1.29
GPL (>= 3)
Authors
Dylan Beaudette [aut, cre], Pierre Roudier [aut, ctb], Andrew Brown [aut, ctb]
Initial release
2021-04-05

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.