Learn R Programming

oce (version 0.2-1)

enuToOtherAdp: Convert ADP from east-north-up coordinates to other coordinates

Description

Convert ADP velocity components from an enu-based coordinate system to another system, perhaps to align axes with the coastline.

Usage

enuToOtherAdp(x, heading=0, pitch=0, roll=0)

Arguments

x
an object of class "adp".
heading
number or vector of numbers, giving the angle, in degrees, to be added to the heading. See Details.
pitch
as heading but for pitch.
roll
as heading but for roll.

Value

  • An object with data$ma$v[,1:3,] altered appropriately, and metadata$oce.coordinate changed from enu to other.

Details

The supplied angles specify rotations to be made around the axes for which heading, pitch, and roll are defined. For example, an eastward current will point southeast if heading=45 is used. The returned value has heading, pitch, and roll matching those of x, so these angles retain their meaning as the instrument orientation.

NOTE: this function works similarly to xyzToEnuAdp, except that in the present function, it makes no difference whether the instrument points up or down, etc.

References

RD Instruments, 1998. ADP Coordinate Transformation, formulas and calculations. P/N 951-6079-00 (July 1998)

See Also

See read.adp for other functions that relate to objects of class "adp".

Examples

Run this code
library(oce)
data(adp)
o <- enuToOtherAdp(adp, heading=-31.5)
plot(o, which=1:3)

Run the code above in your browser using DataLab