Adds one or more columns from species_info to the CA and/or HL
elements of a DATRAS-like object by matching Valid_Aphia in the table
to WoRMS_AphiaID in species_info.
The function preserves the original row order of each table and performs
a left join, meaning that rows with no matching species information are
retained and receive NA in the added columns.
For this type of lookup, the function uses base::match(), which is
typically faster and simpler than base::merge() when only selected
columns need to be appended and the original row order should be kept.
Value
The input object x, with the requested columns added to the CA and/or
HL elements where present.
