Package 'ColumbusGPS'

Title: Process Columbus GPS Files
Description: Small package with a few functions for processing files from Columbus GPS units used in PER studies.
Authors: Travis Hinkelman
Maintainer: Travis Hinkelman <[email protected]>
License: MIT + file LICENSE
Version: 0.1.0
Built: 2025-03-02 03:18:17 UTC
Source: https://github.com/EnvironmentalScienceAssociates/ColumbusGPS

Help Index


Adjust datetime

Description

Adjust datetime string from UTC to pacific timezone or vice versa.

Usage

adjust_datetime(datetime_str, type = c("to_pacific", "to_utc"))

Arguments

datetime_str

Datetime string in YYYY-MM-DD HH:MM:SS format

type

Direction for timezone adjustment: to_pacific or to_utc

Examples

# Daylight Savings Time started on 2022-11-06
adjust_datetime(c("2022-11-05 12:00:00", "2022-11-07 12:00:00"), "to_pacific")

Get sample date

Description

Get the sample date from datetime strings based on threshold time (to accommodate sampling that extends beyond midnight).

Usage

get_sample_date(datetime_str, threshold_time = "05:00:00")

Arguments

datetime_str

Datetime string in the format YYYY-MM-DD HH:MM:SS

threshold_time

Time string in the format HH:MM:SS

Examples

get_sample_date(c("2023-01-05 23:00:00", "2023-01-06 03:00:00", "2023-01-06 06:00:00"))

Prep data file

Description

Prep Columbus GPS data file.

Usage

prep_data_file(data_file)

Arguments

data_file

Path to Columbus GPS data file


Prep datetime

Description

Combine YYMMDD date and HHMMSS time into YYYY-MM-DD HH:MM:SS datetime.

Usage

prep_datetime(date_str, time_str)

Arguments

date_str

Date string in YYMMDD format

time_str

Time string in HHMMSS format

Examples

prep_datetime("221212", "143000")

Prep lat/lon data

Description

Convert string representation of decimal degrees to numeric.

Usage

prep_lat_lon(x)

Arguments

x

String representing decimal degrees that end in N,S,E,W

Examples

prep_lat_lon(c("121.51W", "121.51E"))
prep_lat_lon(c("38.24N", "38.24S"))