Skip to content

Commit

Permalink
adp.xyz2enu() subtracts heading.bias from the heading (instead of add…
Browse files Browse the repository at this point in the history
…ing or ignoring)
  • Loading branch information
dankelley committed Jun 30, 2010
1 parent 80eaa2b commit a5b0981
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: oce
Version: 0.1-81
Date: 2010-06-28
Date: 2010-06-30
Title: Analysis of Oceanographic data
Author: Dan Kelley <[email protected]>
Maintainer: Dan Kelley <[email protected]>
Expand Down
1 change: 1 addition & 0 deletions NEWS
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
0.1-81
- adp.xyz2enu(): make it correct for heading.bias
- make.filter(): can now produce tskernel type
- improve (but temporarily limit) fill.gap
- to plot.adp() add argument use.layout
Expand Down
6 changes: 3 additions & 3 deletions R/adp.R
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ print.summary.adp <- function(x, digits=max(6, getOption("digits") - 1), ...)
cat(" * Beam pattern: ", x$metadata$beam.pattern, "\n", ...)
cat(" * Pings per ensemble: ", x$metadata$pings.per.ensemble, "\n", ...)
cat(" * Heading alignment: ", x$metadata$heading.alignment, "\n", ...)
cat(" * Heading bias: ", x$metadata$heading.bias, "\n", ...)
cat(" * Heading bias: ", x$metadata$heading.bias, "[note: this is *subtracted* from the object's data$ts$heading by adp.xyz2enu()]\n", ...)
} else if (x$instrument.type == "nortek aquadopp high resolution") {
cat("* Nortek-specific:\n\n", ...)
cat(" * Internal code version: ", x$metadata$internal.code.version, "\n", ...)
Expand Down Expand Up @@ -593,8 +593,8 @@ adp.xyz2enu <- function(x, declination=0, debug=getOption("oce.debug"))
pitch <- res$data$ts$pitch
roll <- res$data$ts$roll
if (x$metadata$instrument.type == "teledyne rdi") {
oce.debug(debug, "adding metadata$heading.bias=", res$metadata$heading.bias, "to the heading of this RDI instrument\n")
# heading <- heading + res$metadata$heading.bias # FIXME: I do *NOT* know if this is right. What is in the file? Heading or heading+EB??
oce.debug(debug, "subtracting metadata$heading.bias=", res$metadata$heading.bias, "to the heading of this RDI instrument\n")
heading <- heading - res$metadata$heading.bias # not documented well by RDI; this is from email exchange 2010-06-28-29
if (res$metadata$orientation == "upward") {
oce.debug(debug, "adding 180deg to the roll of this RDI instrument, because it points upward\n")
roll <- roll + 180
Expand Down

0 comments on commit a5b0981

Please sign in to comment.