Skip to content

Commit

Permalink
updating documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
collinschwantes committed Jul 31, 2024
1 parent e570c1f commit afb62d7
Show file tree
Hide file tree
Showing 4 changed files with 41 additions and 3 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Description: This package provides useful functions to orchestrate analytics and
License: MIT + file LICENSE
Encoding: UTF-8
LazyData: true
RoxygenNote: 7.3.2
RoxygenNote: 7.3.2.9000
Suggests:
knitr,
rmarkdown
Expand Down
1 change: 1 addition & 0 deletions NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ export(get_species_letter)
export(guess_col_type)
export(id_checker)
export(make_report_urls)
export(obfuscate_gps)
export(othertext_lookup)
export(read_excel_all_sheets)
export(read_googlesheets)
Expand Down
5 changes: 3 additions & 2 deletions R/obfuscate_gps.R
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
#'
#' @examples
#'
#' gps_data <- data.frame(lat = c(1.0001, 10.22223, 4.00588), lon = c(2.39595, 4.506930, -60.09999901))
#' gps_data <- data.frame(lat = c(1.0001, 10.22223, 4.00588),
#' lon = c(2.39595, 4.506930, -60.09999901))
#'
#' gps_data |>
#' # default obfuscation settings correspont to roughly a 27 by 27 km area
Expand All @@ -25,7 +26,7 @@
obfuscate_gps <- function(x, precision = 2, fuzz = 0.125){

# fuzz point
gps_error <- runif(1,min = -fuzz, max = fuzz)
gps_error <- stats::runif(1,min = -fuzz, max = fuzz)
x_fuzz <- x + gps_error

# round to 2 decimal points
Expand Down
36 changes: 36 additions & 0 deletions man/obfuscate_gps.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit afb62d7

Please sign in to comment.