From f0b327b678e735515d040e6cc4623721d1dd6bf9 Mon Sep 17 00:00:00 2001 From: Dan Kelley Date: Mon, 5 Mar 2012 12:32:57 -0400 Subject: [PATCH] RDI adp distance change in formula --- R/adp.R | 2 +- R/adp.rdi.R | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/R/adp.R b/R/adp.R index f8e9daf4d0..d255994bf0 100644 --- a/R/adp.R +++ b/R/adp.R @@ -303,7 +303,7 @@ summary.adp <- function(object, ...) cat("* Coordinate system: ", object@metadata$coordinateSystem, "[originally],", object@metadata$oceCoordinate, "[presently]\n", ...) cat("* Frequency: ", object@metadata$frequency, "kHz\n", ...) cat("* Beams: ", object@metadata$numberOfBeams, if (!is.null(object@metadata$oceBeamUnattenuated) & object@metadata$oceBeamUnattenuated) "beams (attenuated)" else "beams (not attenuated)", - "oriented", object@metadata$orientation, "with angle", object@metadata$beam.angle, "deg to axis\n", ...) + "oriented", object@metadata$orientation, "with angle", object@metadata$beamAngle, "deg to axis\n", ...) if (!is.null(object@metadata$transformationMatrix)) { digits <- 4 cat("* Transformation matrix::\n\n") diff --git a/R/adp.rdi.R b/R/adp.rdi.R index f4b9077e41..63c02b10b7 100644 --- a/R/adp.rdi.R +++ b/R/adp.rdi.R @@ -598,7 +598,7 @@ read.adp.rdi <- function(file, from=1, to, by=1, tz=getOption("oceTz"), bottomRange[bottomRange.na] <- NA data <- list(v=v, a=a, q=q, bottomRange=bottomRange, bottomVelocity=bottomVelocity, - distance=seq(bin1Distance, by=cellSize, length.out=numberOfCells), + distance=seq(bin1Distance+cellSize, by=cellSize, length.out=numberOfCells), time=time, pressure=pressure, temperature=temperature, @@ -609,7 +609,7 @@ read.adp.rdi <- function(file, from=1, to, by=1, tz=getOption("oceTz"), roll=roll) } else { data <- list(v=v, a=a, q=q, - distance=seq(bin1Distance, by=cellSize, length.out=numberOfCells), + distance=seq(bin1Distance+cellSize, by=cellSize, length.out=numberOfCells), time=time, pressure=pressure, temperature=temperature,