lon360 {oce}R Documentation

Change Longitude From -180:180 to 0:360 Convention

Description

For numerical input, including vectors, matrices and arrays, lon360() simply calls ifelse() to add 360 to any negative values. For section objects, it changes longitude in the metadata slot and then calls itself to handle the ctd objects stored as as the entries in station within the data slot. For this ctd object, and indeed for all non-section objects, lon360() changes longitude values in the metadata slot (if present) and also in the data slot (again, if present). This function is not useful for dealing with coastline data; see coastlineCut() for such data.

Usage

lon360(x)

Arguments

x

either a numeric vector or array, or an oce object.

Examples

lon360(c(179, -179))

[Package oce version 1.8-2 Index]