Learn R Programming

camtrapR (version 2.2.0)

fixDateTimeOriginal: Fix DateTimeOriginal Exif metadata tag in Reconyx Hyperfire cameras

Description

Some camera models don't store the date/time information in the standard Exif metadata tag. Consequently, camtrapR cannot find that information. This function uses Exiftool to update the DateTimeOriginal metadata tag in all images within a directory to make them readable with camtrapR (and other software).

Usage

fixDateTimeOriginal(inDir, recursive = TRUE)

Arguments

inDir

character. Name of the directory containing images to be fixed

recursive

logical. Recursively find images in subdirectories of inDir?

Value

Returns invisibly the messages returned by the Exiftool call (warnings etc.).

Warning

Please make a backup of your images before running this function.

Details

Some Reconyx Hyperfire cameras (e.g. HC500) are known to show this problem.

References

This function uses the code from: Tobler, Mathias (2015). Camera Base Version 1.7 User Guide https://www.atrium-biodiversity.org/tools/camerabase/files/CameraBaseDoc1.7.pdf

Examples

Run this code
# NOT RUN {
# }
# NOT RUN {
# a hypothetical example

wd_images_hyperfire <- "C:/Some/Directory"

fixDateTimeOriginal(inDir     = wd_images_hyperfire,
                    recursive = TRUE)
# }
# NOT RUN {
# }

Run the code above in your browser using DataLab