Select drone videos that contain photoidentified individuals by matching timings of the drone metadata database with the timing of the relevant metadata of the photoID database. This data frame will be passed to droneTrim() function to generate either drone video clips or screenshots of the drone videos with the identified individuals.

selectVideos(
  data,
  data_datetime = NULL,
  video_metadata,
  video_datetime = c("video", "srt"),
  format_data_datetime = "%Y/%m/%d %H:%M:%S",
  keep_all = FALSE,
  timezone = NULL,
  export = NULL
)

Arguments

data

a dataframe containing all the metadata of the photographs, as produced by the function getPhotoMetadata(), or a dataframe with observational data with time and date.

data_datetime

a character giving the column name of the date-time variable.

video_metadata

a dataframe containing all the metadata of the drone videos, as produced by the function getVideoMetadata()

video_datetime

Choose between the datetime extracted from the 'video' (default) or the 'srt' file.

format_data_datetime

character string giving a date-time format as used by strptime. Note that format is ignored if provided when data is a dataframe produced by the function getPhotoMetadata().

keep_all

logical. If TRUE, return all the observations from photoid_metadata, otherwise returns only the pictures matching videos in video_metadata

timezone

string. Add the correct timezone where the drone videos were taken, as per the R base notation (for additional information, see help(timezomes)). Should this argument be left empty, the time zone will be assumed to be the same as the computer system.

export

full path AND .csv filename to where the dataframe should be exported to. E.g. export = '/Users/you/Database/selected_videos.csv'. Should the data not be exported, export=NULL

Value

a data frame with the metadata of the drone videos included in the dataframe containing the metadata of the photographs. From this dataframe, the function getVideoClip will generate either video clips or screenshots of the videos with the identified individuals.

Author

Mauricio Cantor, Alexandre Machado

Examples

if (FALSE) selected_videos <- selectVideos(video_metadata = myVideoMetadata, photoid_metadata = myPhotoMetadata, keep_all = FALSE, timezone='America/Sao_Paulo', export = NULL)