get_hab_exp_across_days: Analysis of rates of habitat exploration.

View source: R/xtracks.R

get_hab_exp_across_daysR Documentation

Analysis of rates of habitat exploration.

Description

Following Wood et al. 2021, this analysis computes the habitat visited / explored each day, the marginal 'new' habitat visited for each day, and the cumulative habitat explored across all days.

Usage

get_hab_exp_across_days(list_of_xtracks, cell_size_m = 10)

Arguments

list_of_xtracks

This analysis should be done with a temporally-sorted list of xtrack objects, with each xtrack representing one day of travel of the same person. In the list, the first day of data should be in position 1.

cell_size_m

The x and y size of each raster cell in the raster representation of the landscape, in meters.

Value

A dataframe (format described below) in which rows represent days, and columns provide analysis outcomes

day

day number

sum_cells_visited_this_day

the number of cells intersected on that day

cum_sum_cells_visited_across_days

cumulative number of cells intersected from day 1 to current day

n_new_cells_visited_this_day

number of cells visited that day and not on prior days

square_meters_per_cell

the area of each cell in square meters

sum_square_meters_visited_this_day

area in square meters of all cells visited that day

cum_sum_square_meters_visited_across_days

cummulative area of cells visited from day 1 to the current day

square_meters_new_habitat_visited_this_day

the square meters of cells visited on that day and not on prior days.

See Also

For Land exploration analysis described in Wood et al. 2021 publication see https://www.nature.com/articles/s41562-020-01002-7#Sec15

Examples

xt_1 <- xtrack(lat=d1$lat, lon=d1$lon, elevation_m=d1$elevation_m, in_camp=d1$in_camp, unix_time=d1$unix_time, distance_from_camp_m=d1$distance_from_camp_m, utm_epsg=32736)
xt_2 <- xtrack(lat=d2$lat, lon=d2$lon, elevation_m=d2$elevation_m, in_camp=d2$in_camp, unix_time=d2$unix_time, distance_from_camp_m=d2$distance_from_camp_m, utm_epsg=32736)
xt_3 <- xtrack(lat=d3$lat, lon=d3$lon, elevation_m=d3$elevation_m, in_camp=d3$in_camp, unix_time=d3$unix_time, distance_from_camp_m=d3$distance_from_camp_m, utm_epsg=32736)
xt_4 <- xtrack(lat=d4$lat, lon=d4$lon, elevation_m=d4$elevation_m, in_camp=d4$in_camp, unix_time=d4$unix_time, distance_from_camp_m=d4$distance_from_camp_m, utm_epsg=32736)
xt_5 <- xtrack(lat=d5$lat, lon=d5$lon, elevation_m=d5$elevation_m, in_camp=d5$in_camp, unix_time=d5$unix_time, distance_from_camp_m=d5$distance_from_camp_m, utm_epsg=32736)
xt_6 <- xtrack(lat=d6$lat, lon=d6$lon, elevation_m=d6$elevation_m, in_camp=d6$in_camp, unix_time=d6$unix_time, distance_from_camp_m=d6$distance_from_camp_m, utm_epsg=32736)
xt_7 <- xtrack(lat=d7$lat, lon=d7$lon, elevation_m=d7$elevation_m, in_camp=d7$in_camp, unix_time=d7$unix_time, distance_from_camp_m=d7$distance_from_camp_m, utm_epsg=32736)
xt_8 <- xtrack(lat=d8$lat, lon=d8$lon, elevation_m=d8$elevation_m, in_camp=d8$in_camp, unix_time=d8$unix_time, distance_from_camp_m=d8$distance_from_camp_m, utm_epsg=32736)
list_of_xtracks <- list(xt_1, xt_2, xt_3, xt_4, xt_5, xt_6, xt_7, xt_8)
hab_exp_results <- get_hab_exp_across_days(list_of_xtracks, cell_size_m = 10)

brianwood1/xtracks documentation built on Oct. 12, 2022, 7:42 a.m.