Volume 7, Issue 8
Research Article
Free Access

Socially interacting or indifferent neighbours? Randomization of movement paths to tease apart social preference and spatial constraints

Orr Spiegel

Corresponding Author

Department of Environmental Science and Policy, University of California, Davis, Wickson Hall, One Shields Avenue, Davis, CA, 95616 USA

Correspondence author. E‐mail: orr.spiegel@mail.huji.ac.ilSearch for more papers by this author
Stephan T. Leu

School of Biological Sciences, Flinders University, GPO Box 2100, Adelaide, SA, Australia

Search for more papers by this author
Andrew Sih

Department of Environmental Science and Policy, University of California, Davis, Wickson Hall, One Shields Avenue, Davis, CA, 95616 USA

Search for more papers by this author
C. Michael Bull

School of Biological Sciences, Flinders University, GPO Box 2100, Adelaide, SA, Australia

Search for more papers by this author
First published: 23 February 2016
Citations: 43

Summary

  1. Understanding how animals interact with their physical and social environment is a major question in ecology, but separating between these factors is often challenging. Observed interaction rates may reflect social behaviour – preferences or avoidance of conspecifics or certain phenotypes. Yet, environmental spatiotemporal heterogeneity also affects individual space use and interaction rates. For instance, clumped and ephemeral resources may force individuals to aggregate independently of sociality.
  2. Proximity‐based social networks (PBSNs) are becoming increasingly popular for studying social structures thanks to the parallel improvement of biotracking technologies and network randomization methods. While current methods focus on swapping individual identities among network nodes or in the data streams that underlies the network (e.g. individuals movement paths), we still need better tools to distinguish between the contribution of sociality and other factors towards those interactions.
  3. We propose a novel method that randomizes path segments among different time stamps within each individual separately (Part I). Temporal randomization of whole path segments (e.g. full days) retains their original spatial structure while decoupling synchronization among individuals. This allows researchers to compare observed dyadic association rates with those expected by chance given explicit space use of the individuals in each dyad.
  4. Further, since environmental changes are commonly much slower than the duration of social interactions, we can differentiate between these two factors (Part II). First, an individual's path is divided into successive time windows (e.g. weeks), and days are randomized within each time window. Then, by exploring how the deviations between randomized and observed networks change as a function of time window length, we can refine our null model to account also for temporal changes in the activity areas.
  5. We used biased‐correlated random walk models to simulate populations of socially indifferent or sociable agents for testing our method for both false‐positive and negative errors. Applying the method to a data set of GPS‐tracked sleepy lizards (Tiliqua rugosa) demonstrated its ability to reveal the social organization in free‐ranging animals while accounting for confounding factors of environmental spatiotemporal heterogeneity. We demonstrate that this method is robust to sampling bias and argue that it is applicable for a wide range of systems and tracking techniques, and can be extended to test for preferential phenotypic assortment within PBSNs.

Introduction

Understanding how animals interact with their physical and social environment is a major question in behavioural and evolutionary ecology with implications for conservation and management (Whitehead 2008; Farine, Montiglio & Spiegel 2015; Kays et al. 2015). However, since environmental heterogeneity often affects social interactions through constraints imposed on animal space use (Bejder, Fletcher & BrÄger 1998; Wolf et al. 2007; Carter et al. 2009), teasing apart physical and social factors is often challenging. Social network analyses are increasingly popular for exploring the dynamics, development and evolution of complex social systems and processes such as information transfer, disease spread and collective movements (Sih, Hanser & McHugh 2009; Krause, James & Croft 2010; Bode, Wood & Franks 2011; Pinter‐Wollman et al. 2014). Other studies have used social networks to study social structure, connectedness and sociability or affinity among individuals (Leu et al. 2010; Wey & Blumstein 2010; Wilson et al. 2012; Godde et al. 2013).

Proximity‐based social networks (PBSNs; a.k.a spatial or contact networks) are derived from the frequency of pairwise spatial associations among individuals. Although they cannot discriminate among types of interactions (i.e. agonistic vs. affiliative), they are often used in species that are hard to observe visually in their natural environment or that move over large spatial scales (e.g. dolphins: Lusseau 2003; guppies: Wilson et al. 2014; sleepy lizards: Godfrey et al. 2012). Spatial associations can be inferred from various biotelemetry methods (PIT tags, Aplin et al. 2013; acoustic tags, Finn et al. 2014; radiotelemetry, Templeton et al. 2011; GPS tags, Godfrey, Sih & Bull 2013). Rapid development of better, lighter and cheaper technologies is expected to enhance the use of PBSNs by offering new opportunities to track more individuals from a wider range of species (Haddadi et al. 2011; Kays et al. 2015).

While PBSNs can describe complex social patterns and association preferences, identifying factors that shape these patterns is often challenging (Whitehead & James 2015). Observed network structure may reflect either a social response to conspecifics (often referred to as dynamic interactions; Long et al. 2014) and/or associations resulting from the spatial structure of the environment (Wolf et al. 2007; Godde et al. 2013; Pinter‐Wollman et al. 2014). High association rates may result from conspecific attraction or from the presence of an essential resource that attracts individuals independent of sociality (e.g. a waterhole). For instance, the spatial structure of the habitat has been shown to result in aggregations in sharks (Mourier, Vercelloni & Planes 2012) and kangaroos (Carter et al. 2009). Similarly, observed association patterns may be confounded by temporal structuring of animal space use. Ephemeral resources may drive animals to aggregate at a given patch during a discrete time window, but not at other times (Minta 1992; Croft et al. 2011). For instance, savanna waterholes attract aggregations mostly during the dry season, and altitudinal zonation may force many individual insects to track seasonal progress together along an elevation gradient.

Comparing observed association patterns with those expected under certain null models allows testing specific hypotheses about structuring mechanisms that shape the social network. Yet, despite these examples of environmental effects on association rates, earlier null models relied on simplistic representation of movement. For example, the ideal gas model assumes homogenous movement of an individual within its home range (HR), whereas real movement patterns are normally structured in time and space. Increasingly detailed knowledge from movement ecology (Holyoak et al. 2008; Kays et al. 2015; Spiegel et al. 2015a) allows researchers to develop more appropriate null models for expected association rates (e.g. based on heterogeneous HR use), which then can be compared to the empirical observations.

An alternative approach is to use network randomizations for hypothesis testing in social networks. This approach is generally simpler to implement and copes well with the structure of the data and the dependencies that characterize networks (Croft et al. 2011; Whitehead & James 2015). Randomization methods include randomizing edge weights or swapping the identities of individuals in the network (typically its nodes). More recently, identity swapping in the data stream used to build the network (e.g. Farine 2014; Godfrey et al. 2014; Leu et al. 2016) was shown to be less error prone and to relax assumptions of homogenous space use by swapping only individuals co‐occurring at the same site and time (Farine 2015; Farine & Whitehead 2015). Overall, although these methods can test whether given individuals or dyads interact more or less than expected by chance, they cannot discriminate between the roles of spatial heterogeneity and social attraction in shaping network structure because the locations and timing of observed associations are carried over to the randomized networks. For instance, by switching males and females, we can determine sex preferences in network associations but not whether clusters of associations were caused by social attraction or by the presence of an environmental attractor.

We present a new data stream randomization method that generates null models for PBSNs by randomizing movement paths within individuals (instead of swapping them between individuals, as done in methods described above). Our method provides advantages of both physical null models and network randomizations. First, it allows us to determine whether observed associations differ from those expected by chance (i.e. when focal individuals show no social preferences) while accounting for nonhomogenous space use within HRs (Part I). Secondly, since social interactions are typically much shorter than the more gradual changes in the environment, by adjusting the randomization time window, we can differentiate between the contributions of social preference and other factors to the observed spatial association rates (Part II). We test our method on two PBSN types: first, networks based on associations of agents simulated using biased‐correlated random walk models; and secondly, a PBSN of GPS‐tracked sleepy lizards (Tiliqua rugosa). The simulated data sets demonstrate controlled set‐ups of known structures of socially indifferent or sociable agents (see below). The empirical data set demonstrates how this method can reveal social organization in free‐ranging animals while accounting for environmental heterogeneity that may influence their association rates.

Methods and results

In a PBSN, an association between two individuals is defined if they are within a chosen spatial proximity at a given time point (threshold values are a product of the biology of the study system, e.g., species perceptual range; Haddadi et al. 2011). For each interacting dyad, the strength of their edge can be calculated by indices such as the simple ratio index (SRI) or the similar half‐weight index (Godde et al. 2013). SRI divides the number of observed associations by the number of overlapping time points for this dyad in the data set. Here, we will focus on two widely used social network indices for an individual: node degree (the number of individuals it associated with) and edge weight (the mean SRI for all nonzero edges). We used indices of the observed network structure (mean degree and edge weight over all individuals) as test statistics and compared them with a distribution obtained from multiple simulated PBSNs following our randomization procedure implementing the assumptions of the null model (hereafter PBSN realizations). Deviation of the network indices from this distribution suggests a nonrandom association network and a structured social organization (Whitehead 2008; Croft et al. 2011).

Part I: Path‐Randomization Method – A New Null Model for Observed PBSNs

We propose a temporal shuffling of the spatial movement paths, randomly reordering the paths of given time blocks (or segments) from the i‐th individual while maintaining the temporal path sequence within each time block. For example, using a data set of the movement paths of 60 individuals over a 125‐day period, we retain the movement path each individual intact within each day, but randomly reorder the sequence of days for each of the 60 individuals. This achieves two goals. First, we maintain the spatial aspects of the original movements of each individual, reflecting any spatial heterogeneity within its HR. Secondly, by randomizing paths of different individuals independently of each other, we decouple temporal dependencies among them. Individuals observed interacting in the empirical PBSN still visit the same locations after randomization (the spatial coordinates are kept), but not necessarily on the same day. After randomizing the paths of all individuals, a PBSN realization is reconstructed and network indices are recalculated. The frequency distribution for each network index is derived from multiple realizations. Practically, to maintain the path sequence within each time block, the order of days is randomized while the time of day (HH:mm) is kept unchanged. Although such a daily hierarchy will be the most straightforward application for many ecological studies where the species has a daily activity cycle, the temporal scale should match the animal system and the ecological question in mind, and time blocks can be hours, months or any other appropriate interval.

An obvious issue with any random reordering of movement data is breaking the natural spatial autocorrelation of the path. In real life, the positional changes of an individual are constrained by its movement speed and time interval between measurements. A randomized path, where an individual ‘jumps’ in space, violates this important constraint. Yet, randomly reordering daily blocks as complete units minimizes this issue to the time steps between blocks. These ‘jumps’ will only occur between the last location of one block and first location of the following (randomly selected) block. As we show below, with simulated data sets, this does not affect our estimations of PBSN indices.

Validating Our Method Using Simulated Agent Populations

To ensure that our method functions adequately, we tested it with PBSNs from simulated populations with known social structures. Simulations were obtained by different scenarios of biased‐correlated random walk (BCRW) that are commonly used in ecology (Turchin 1998; Spiegel, Getz & Nathan 2013; Langrock et al. 2014). These models run on discrete time steps, in which each agent takes a step with length L in direction μ. This direction reflects a compromise between a bias towards the agent's bias point (typically its origin and HR centre) and a correlation with the direction of its previous step. The correlation component simulates movement inertia, and the bias component usually reflects confined HRs (in contrast to simple random walks where displacement from the start point increases with time). Model parameters (e.g. density, daily travel distance, displacement and HR size) were chosen to correspond with the empirical lizard data described below (see Appendix S1, Supporting information, for further details). However, the simulations were not compared with the empirical data set nor were they intended to reproduce the same patterns. Our comparisons were always between the original simulated PBSN (built using the same association distance as for the empirical data set) and its realizations after path randomization.

A paired t‐test compared individuals' index value in the original PBSN with their average degree from 100 realizations of the PBSN. We also quantified the population‐level probability of finding K agents having a smaller degree (in the original PBSN) than expected (their mean degrees in the realizations): B (N, 0·5), P (≤ K), where N is the number of individuals in the population, X is a random variable from a binomial distribution with success rate of 0·5 and P is the one‐sided probability of observing X equal to or smaller than K or X equal or larger than N‐K. An alternative approach where P is estimated from a comparison of population's mean degree with results for mean degree from 100 simulated population gave similar results. Here, we present the former approaches since they facilitate comparison also at the individual level. We made similar comparisons for edge weight of each agent.

First, to control for false‐positive (Type I) errors, we simulated a population of randomly distributed socially indifferent agents that are neither attracted to nor repulsed by conspecifics. In this simulation (hereafter the ‘static activity‐areas’ scenario), agents move within their HR and are not affected by other agents (Fig. 1). All spatial associations among them result from random encounters. Therefore, the original PBSN (constructed for the simulated tracks) is not expected to differ from realizations generated by path randomizations of these tracks. Applying our method should not affect network indices. Constructing the PBSN for this simulated population resulted in a total of 7300 dyadic spatial associations. Each agent had 243·3 ± 200·0 associations (mean ± SD, range: 4–725), a degree of 5·87 ± 2·90 (1–11) and an edge weight of 0·0487 ± 0·0400 (0·0008–0·145). As expected, values obtained after path randomizations were similar to those of the original PBSN, demonstrating that path randomization does not lead to a false‐positive detection of social structure in a population of socially indifferent agents (Degree: T59 = 0·62, = 0·53; B (60, 0·5), P ( 26) = 0·18; edge weight: T59 = 0·32, = 0·75; B (60, 0·5), P ( 35) = 0·12; Fig. S1).

image
Maps of simulated agent populations. We developed biased‐correlated random walk (BCRW) models to simulate populations with known social structures and used their proximity‐based social networks (PBSNs) to validate our proposed movement‐path randomization. Points are agents' (N = 60) origins in four different scenarios, with 10 exemplar paths shown in each panel. (a) Static activity‐areas: agents are socially indifferent and have a bias towards their origin (i.e. a static HR). (b) Paired agents: agents have static HR and conspecific‐attraction towards their mate, but are socially indifferent to all other agents. Black lines indicate paired agents. (c) Sociable agents: agents have conspecific‐attraction towards the nearest neighbor and no bias towards their origin. (d) Changing activity areas: agents are socially indifferent and their bias point drifts during the simulation (black lines).

Secondly, to control for false‐negative (Type II) errors, we constructed a scenario in which agents are attracted to a (permanent) partner located nearby and socially indifferent to all other agents (Fig. 1). In this ‘paired agents’ scenario (inspired by the sleepy lizard pair‐living social organisation; Bull 1988), randomizations are expected to strongly reduce mean edge weight (since they disrupt the synchronized movements of pairs) but not their degree (that is largely random). Here, the original PBSN included more dyadic associations than the in ‘static activity areas’ scenario: each agent had 513·1 ± 222·0 (219–1109) associations (a total of 30 782), a degree of 6·9 ± 3·5 (1–15) and an edge weight of 0·103 ± 0·044 (0·044–0·222). As expected, values obtained after path randomizations (Fig. 2) were similar for degree (T59 = –0·76, = 0·4; B (60, 0·5), P ( 31) = 0·35) but significantly lower than the original PBSN for edge weight (0·0704 ± 0·0344; T59 = 13·8, = 3·9 × 10−20; B (60, 0·5), P ( 0) = 8·6 ×10−19). The difference in edge weight is attributed solely to the effect of randomizations on within‐pair associations (T29 = 8·5, = 1·8 × 10−9; B (30, 0·5), P ( 0) = 9·3 × 10−10) whereas edge weight for other associations did not change by the randomization (T26 = 1·1, = 0·26; B (27, 0·5), P ( 16) = 0·13 Fig. S2).

image
The effect of proximity‐based social network (PBSN) randomization on individuals’ degree (a, b) and edge weight (c, d) for ‘paired agents’ simulation (a, c) and GPS‐tracked lizards (b, d). For each agent, index value in the original PBSN (solid, thick, red line) is compared with the corresponding range of values from 100 realizations (blue boxplot: 25th to 75th percentiles, whiskers: 1·5 interquartile distance). The insets to the right present histograms of the mean index values for the entire population across realizations (red dashed line – the original PBSN). As expected, the original PBSN for the simulated data differed from the randomized PBSNs only in edge weights (see Fig. S2 for partitioning of pair bonds and nonpair bonds) but not in degree. For the empirical data, both degrees and edge weights were remarkably different from the randomizations, indicating conspecific attraction in lizards.

Further, since empirical data sets often suffer from gaps in the data and uneven sampling across individuals we have used the ‘paired agents’ scenario to test the robustness of our method to these issues (see Appendix S1 for further details). This analysis showed (Fig. S3) that our randomization method provides consistent and accurate results even when significant portions of the data are absent (for instance, if 50% of the simulated agents have 50% of their data points missing). Finally, we constructed a third scenario of ‘sociable agents’ with conspecific attraction to all agents, where, as expected, randomizations affected both degree and edge weight by disrupting synchrony in movements among dyads (see Appendix S1).

Applying Our Method to an Empirical Data Set of Sleepy Lizards

To demonstrate how the proposed method might be applied, we used an empirical data set from a population of free‐ranging sleepy lizards (T. rugosa) at Bundey Bore Station in South Australia (33°54′S, 139°20′E). This system and the tracking methods used to derive movement paths and PBSNs have been previously described (Leu, Kappeler & Bull 2011b; Spiegel et al. 2015b and references therein). For consistency with these publications, we defined an association if two individuals were recorded within 14 m of each other, for constructing PBSNs. Sleepy lizards are only active during the austral spring (September–December), feed mostly on flowering annual plants and reduce activity towards summer as these resources dry out (Kerr & Bull 2006). Male lizards closely follow females for periods of 6–8 weeks before mating in late October (Bull 1988; Leu, Kappeler & Bull 2011a). Adults occupy stable and partially overlapping HRs, sharing HR‐cores mostly with mates (Bull 1995; Kerr & Bull 2006). During the spring of 2010, we tracked 60 adult lizards (30 males) using GPS units that recorded synchronized positions of all lizards that were active (determined by a step counter) at 10‐min intervals. We compared degree and edge weight of individuals in the observed network with their mean values over 100 path randomizations as described above.

On average, lizards were tracked for 99·8 ± 14·7 days (60–115), had a daily path length of 374 ± 212 m (0–1401) and a maximum daily displacement of 82 ± 56 m (0–562). Since tracking beginnings were not perfectly synchronized, our tracking season span over 125 days in total. Lizards PBSN included 10 805 associations. Individuals each had 360·2 ± 251·3 (2–1014) associations, a degree of 10·8 ± 4·40 (2–23) and an edge weight of 0·241 ± 0·143 (0·0019–0·5316). Observed degree was significantly higher (by 1·2 ± 1·4; range: −1·9 to 5·3) than expected from their path randomized PBSN realizations (Fig. 2; T59 = 6·9, = 4 × 10−9), implying that most lizards (n = 47) interacted with more individuals, and only 13 interacted with fewer individuals than expected from the null model (B (60, 0·5), P ( 13) = 6 × 10−6). Observed edge weight was also significantly stronger (by 0·1653 ± 0·1210, range −0·0233 to 0·4054) than the null expectation (Fig. 2; T59 = 10·3, = 8 × 10−15). This was the case for 55 lizards (B (60, 0·5), P ( 5) = 5 × 10−12).

Part II: Accounting for Temporal Dynamics by Time Window Adjustment

In addition to the effects of nonhomogeneous space use within the HR addressed by Part I, the observed PBSN may also reflect the responses of individuals to environmental changes over time. Synchronized movement may result from external cues (e.g. human pedestrians synchronize crossing streets based on traffic light signals) or from spatiotemporal dynamics in resources. For instance, later in their activity season, sleepy lizards presumably concentrate their activity near dams and local depressions that retain soil moisture, while hot dry summer conditions dry the surrounding landscape. Thus, temporal resource heterogeneity superimposed on social preferences may increase the expected spatial association rates later in the season for this system. Failing to account for such effects may lead to misidentification of the strength of the social structure (see Fig. S4 for an illustrative cartoon). By adjusting the length of the time window (tw) for randomizations, our proposed method can maintain the benefits of decoupling temporal dependencies among movements of individuals while accounting for these more gradual temporal dynamics. In the lizard example, randomizing days from the early season separately from days from the late season can account for the differential space use in these two periods (and the consequential variation in randomly expected encounter rates).

Path randomizations of the data sets presented in part I used the entire simulation length (= 100 days). In part II, we propose to split the data set into nonoverlapping tws and limit the randomization to days within each tw. For a given length of tw, one progresses subsequently through the (D/tw) nonoverlapping tws and randomizes among days within each period. For instance, with a tw = 20 days, a data set = 100 days results in five periods (tws) of 20 days. The path of the 14th day for a given individual can be replaced during randomization with its path from any day between days 1 and 20. After all of the first 20 days for this individual have been randomly reordered, days 21–40 are randomly reordered, then days 41–60 etc. (see illustration in Table S1). Length of tw may range between 2 and D (tw > D is effectively identical to tw = D since all days in the data set are randomized at once). One can use all possible values of tw or focus on a subset that is relevant to the species, and its ecology. Focusing also saves computation time. For instance, a tw of 7 days should ensure randomizations control for possible seasonal changes in activity area. We applied path randomizations to the simulated and empirical data sets using tw values of 2, 3, 5, 10, 25, 50, 75 and 100 days (also 125 days for the lizards data). An example of a continuous change of tw is included in the Appendix S1.

Plotting the deviations between the original PBSN index value (degree or edge weight) and the respective mean value derived from randomizations with different tw lengths as a function of tw allows us to explore environmental dynamics at different time‐scales (e.g. abrupt or gradual). Note that in 1/tw of the cases, dyads will have their original days coinciding in the randomizations. For instance, using a tw of 4 days implies that on average in 1/4 of the days in a given iteration, the original paths of two individuals will coincide and any synchrony in their original paths will be maintained (e.g. the 24th day for both individuals may be independently randomized to be the 22nd). Hence, while shorter tws are expected a priori to result in smaller deviations from the original PBSN, only if these deviations reflect social preference (as in the ‘paired agents’ and ‘sociable agents’ scenarios) or avoidance, will they persist in very short tws. In contrast, if the original PBSN is merely a result of environmental constraints that force individuals to associate at certain locations at certain times, then these deviations will decrease to zero as tw becomes shorter (since association rates from paths randomized over short times will not differ much from the observed patterns).

To illustrate the value of examining a range of tws, we simulated a situation where animals exhibited temporal shifts in HR use. In a temporally varying world, randomizations that include the entire data set (i.e., tw = D) are likely to incorrectly assess the social structure (i.e. to suffer from Type I errors), whereas adjusting tws (a novel feature of our method) can identify and overcome this common potential problem. We investigated this by examining two additional scenarios of the BCRW model where socially indifferent agents changed their activity areas over time, either abruptly after 50 days (‘abruptly changing activity areas’ scenario; Fig. 1) or gradually throughout the simulation (‘gradually changing activity areas’ scenario; see Appendix S1 for additional details). We expected deviations between the original PBSN and randomized networks to differ between randomizations using short and long tws, with a step function (at tw = 50) and a gradual change for the two scenarios, respectively.

Long tws shuffle days in which an agent is active in different areas of its overall HR (e.g. the 23rd day can be replaced with the 75th day). This may create apparent spatial associations among agents that are otherwise active in different areas and lead to an overestimation of their degree in the realizations, thus resulting in a false‐positive signal of social avoidance for the empirical data. In contrast, when short tw values are used, the deviations between the original PBSN and its realizations should be zero for socially indifferent agents but substantial for individuals with true social preferences. For instance, in the abrupt scenario, days 1–50 (before the change in HR) and 51–100 (after the change) will be shuffled separately. Thus, agents should experience the same social environments with the same neighbours throughout all of their randomized paths and have similar degrees to those of the original PBSN. If agents had synchronized movements, the randomization would have interrupted them, showing deviations from the original PBSN (lower indices values). To test these predictions, we applied path randomization with varying tws to the scenarios described in part I and to the lizard data set. The lizard analysis tested whether environmental changes in resource distribution forced lizards to use similar areas concurrently and may explain their higher than random association rates described in part I (Fig. 2).

Introducing a single temporal change in activity areas (a 50‐m shift in HR centre after day 50) did not affect the PBSN structure. There were no differences in mean network degree, edge weight or the number of associations between networks derived from the ‘static activity areas’ and the two ‘changing activity areas’ scenarios (all T118 < 0·45, > 0·4). However, when using a null model that ignored temporal changes of activity centres (i.e. tw = 100), these latter scenarios gave a false‐positive result of social avoidance (Fig. S5). Changing tw had no effect on deviation from the original indices in the ‘static activity areas’ scenario (Fig. 3), but strongly affected indices in the two ‘changing activity areas’ scenarios (Figs 3 and S6). Here, PBSN realizations based on short tws randomizations were similar to the original index values while those using long tws produced higher network degree values (since the randomized paths allow associations among agents that could not meet in the original paths). As expected, the effect of increasing tws in the gradual change scenario (Fig. S6) was similar to the abrupt scenario but without the clear switching point at tw = 50. Long tws (including tw = 100 days, as in Part I) also affected edge weight, but less strongly – merely 1–2 more associations per dyad over the entire simulation, and in opposite directions for the two scenarios. Overall, these results demonstrate how temporal shifts in activity areas induced by environmental dynamics (independent of sociality) may lead to Type I errors in randomization methods that fail to directly account for those effects. They also confirm that the proposed method of tw adjustment can eliminate this error and detect confounding factors associated with both abrupt and gradual shifts in activity areas.

image
The effect of randomization time window (tw) on deviation of the proximity‐based social networks (PBSNs) realization from the original network using two biased‐correlated random walk (BCRW) scenarios. Data points are the deviation of populations’ mean degree (a, b) or edge weight (c, d) with zero baseline as a red dashed line. In the ‘static activity areas’ (a, c), tw has no effect on the deviation. In the ‘abruptly changing activity areas’ scenario, the bias point of the agents changes after 50 days (black arrows) and tw > 50 days results in deviations from the observed PBSN. Error bars are SE of mean values over 100 PBSN realizations. Note log scale for x‐axis and the smaller y scale in c,d compared to other figures.

Applying this method to sociable agents in the ‘paired agents’ or the ‘sociable agents’ scenarios (Figs 4 and S6, respectively) and to the lizard data set (Fig. 4) gave complementary results, demonstrating how effects of social attraction (if present) can be separated from temporal dynamics of space use. Although deviation from the original PBSN decreased as tw shortened (proportionally to tw−1), it remained pronounced even for short tws. For lizards, these pronounced deviations using short tws (Fig. 4, see also Fig. S7 for an example with a continuous change in tw for its entire range) reconfirm the findings obtained with long tws (tw = 125, Part I; Fig. 2) and further discount any alternative (environmental) explanations. Hence, lizards interacted with more conspecifics and more strongly than expected by chance, and this social preference was not an artefact caused by temporal dynamics in environmental constraints on their space use. Interestingly, deviations in edge weight closely followed the expected line (i.e. are proportional to tw−1) whereas deviations in degree were smaller than this expectation for a range of intermediate tws (ca. 5–20 days). This anomaly may be a signature of some constraints imposed by environmental effects (forcing lizards to congregate at certain localities within this time‐scale), thus influencing the number of conspecifics they interacted with (on top of their established social preference). But this specific effect should be more rigorously tested in future studies.

image
The effect of randomization time window (tw) on deviations in degree (a, b) and edge weight (c, d) of the proximity‐based social networks (PBSNs) realizations from their original networks in the ‘paired agents’ simulation (a, c) and the lizards population (b, d). The zero baseline and expected 1/tw fit to the data are presented (red‐dashed and dotted‐black lines, respectively). For simulated data, only deviations in edge weight are significant throughout the whole range of tw, as expected by the break of the pair bonds of these otherwise socially indifferent agents. In contrast, lizards show true conspecific attraction even when environmental spatiotemporal constraints on their space use are accounted for (negative deviations imply lizards interacted more than expected by chance). Error bars are SE of mean values over 100 PBSN realizations. Note log scale for x‐axis.

Discussion

Our method develops null models that test whether the social associations underlying a social network are more or less frequent than would be expected by chance (i.e. whether individuals do or do not have social preference), while accounting for spatial and temporal heterogeneities that might constrain space use independently of the social preferences. Various authors have acknowledged that spatial structures in the environment can influence patterns of PBSNs (Wolf & Trillmich 2007; Carter et al. 2009; Jacoby et al. 2012; Mourier, Vercelloni & Planes 2012; Godde et al. 2013; Pinter‐Wollman et al. 2014). Yet, only a few methods to separate these effects from social factors affecting network structure have been proposed (Carter et al. 2009; Farine 2014; Farine & Whitehead 2015; Whitehead & James 2015). We introduce a simple and widely applicable method to separate spatiotemporal environmental and social effects. First, we randomize the movement paths that underlie the observed PBSN (Part I). In contrary to previous methods (that often rely on identity swapping), by randomizing path segments within individual track, we maintain its space use heterogeneity. Then, we adjust the tw used for these randomizations to identify effects of temporal changes or directional movements (Part II). We test our method using various agent‐based movement simulations and apply it to empirical data from a population of free‐ranging lizards.

In the lizard example, we show they have strong conspecific attraction even when the effects of temporal environmental changes on their movements and nonhomogenous HR use are accounted for. The average degree difference reported here (Figs 2b and 4b) is probably an underestimation since we have incomplete information on peripheral individuals (because their neighbours are largely untagged). The higher empirical edge weight than in the null model (Fig. 2D) implies spatial associations were more frequent than expected by independent use of the same paths. This finding agrees with documented refuge sharing and mate following, and overall social organization of this species (Bull 1995; Leu et al. 2010; Leu, Kappeler & Bull 2011a, b; Godfrey et al. 2012). While these analyses confirm already reported behaviours for this exceptionally well‐studied species, they provide a proof‐of‐concept for the ability of this approach to reliably describe social organization in other, less explored, study systems. These results may also initiate future questions about phenotypic assortment in this species, such as same sex associations, that can extend our insights using these analyses (e.g. whether same‐sex networks show different patterns?).

The Applicability and Limitations of Our Method in Comparison with Other Alternatives

Animal movements generate the spatial associations that allow social interactions and shape the social network. A variety of indices are available to identify dynamic interactions where dyads move in similar directions and distances (Long & Nelson 2013; Long et al. 2014). Yet movements reflect a complex integration of the state of the individual, its motion and navigation capacities, and its interaction with other environmental factors, resources, barriers and predators (Holyoak et al. 2008; Kays et al. 2015). Our null models, using path randomization, offer more realistic representations of movement in time and space, than has been possible in the past. The random gas model (Hutchinson & Waser 2007), for example, assumes unrealistic homogenous movement within HRs without accounting for spatial or temporal structures. We acknowledge that our method (especially of part II) would fail separating between the contributions of sociality and shared space use to the emergent spatial associations if the environment changes in a cycle that is similar or shorter in length than social interactions; for instance, if all individuals always drink at a waterhole every morning or if individuals respond to conspecific scent marks over an extended time but the environment changes very rapidly. While identical temporal scales between constraints and social interactions may remain unsolvable without additional data sets (e.g. on resource dynamics) or experimental approach, future studies that will explore the appropriate adjustments of time blocks (here we used days), for a wider range of temporal changes, can relax the current constraint of applicability to ecological contexts in which environmental changes operate at slower temporal scales than social interactions.

Null models developed by network randomization methods, like ours, benefit from retaining important features and inherent dependencies of the original data and from using a larger part of it (Bejder, Fletcher & BrÄger 1998; Lusseau, Whitehead & Gero 2008; Croft et al. 2011). Farine (2014) has recently indicated the importance of considering spatial constraints when performing randomizations based on nodes or data stream replacement. While identity swapping may break the spatial autocorrelation of individual's paths (even when constrained to individuals within a given site and time frame), to the best of our knowledge the effects of such potential biases, or of biases in the movement‐path data sets (see Appendix S1) have not been formally tested. In our study, we applied our method to various simulation scenarios, with known social organization, and showed that segmenting the paths to distinct blocks and reordering them for each individual separately did not affect our results. A parallel randomization approach that offsets the entire track of a given individual by a varying period (e.g. 1 hour or 1 day are added to the time stamps of an individual) should achieve similar performance, while further minimizing loss of spatial autocorrelation, but this approach is yet to be developed and validated.

Spatial associations in null models constructed by identity swapping maintain the structure (locations and timings) of the original data. Although useful for identifying phenotypic assortment, these models (or any other adjacency matrix‐based randomization) cannot identify the contribution of spatial heterogeneities (e.g. clumped resources) to observed association rates. Conversely, by shuffling movement paths within individuals (independently for each individual), the associations are an emergent property of the null model and may differ from observed data. This allows us to determine whether association rates (for any given dyad or for the network as a whole) differ from expectations based on spatiotemporal heterogeneities (Whitehead & James 2015). Relating these deviations to individual phenotypes is a straightforward extension of the method that will allow scholars to test relevant hypotheses currently being tested by identity swapping. For example, Godfrey et al. (2014) tested whether related female lizards associate less than expected from their space use.

Our method is most suitable where continuous tracking data are available (e.g. from GPS recording; Haddadi et al. 2011). Future applications may include PBSN analyses in an ecological context of synchronized group movement (e.g., Bode, Wood & Franks 2011; Jacobs et al. 2011). A context of collective movement will typically require shorter time block and window ranges, and these values should be carefully adjusted to the appropriate values for the system under study. Moreover, as revealed by our data subsetting analysis (Fig. S3), our method is not sensitive to missing data and biased sampling and can be applied to any data set in which the PBSN is extracted from spatial associations at known spatial locations. Examples include visits of birds to feeders, locations of sharks from photo‐identification or acoustic telemetry (Mourier, Vercelloni & Planes 2012; Aplin et al. 2013; Finn et al. 2014). Many alternative methods effectively ignore important information from data points that do not produce spatial associations among dyads and locations of noninteracting individuals are typically discarded. We suggest using those locations to reconstruct original paths, even in a simplistic form, through interpolation between known locations (e.g. feeder visits). Using a larger portion of the location data in the original data set, we can significantly improve null models. Applying our method across study systems and extending it to identify preferential phenotypic assortments will help explore variation in social structure across species.

Acknowledgements

We thank Ron and Leona Clark and Chris Mosey for allowing us access to their land and the use of the homestead at Bundey Bore Station for gathering the sleepy lizard data. We also thank Dale Burzacott for logistical support, and Tina Wey, Damien Farine, Meg Crofoot and Sih laboratory members for useful feedback and discussions. Lauren Brent and two anonymous reviewers provided useful comments on the original manuscript. We acknowledge funding by the Australian Research Council, the Holsworth Wildlife Research Endowment and NSF grant DEB‐1456730.

    Data accessibility

    We implemented our BCRW models in R with a code adapted from Langrock et al. (2014) and the randomization method in MATLAB (MATLAB and Statistics Toolbox Release 2012, The MathWorks, Inc., Natick, MA, USA). We provide the codes and the example data sets in the Supporting informations (see instructions in Appendix S2).

        Number of times cited according to CrossRef: 43

        • Genetic relatedness cannot explain social preferences in black-and-white ruffed lemurs, Varecia variegata, Animal Behaviour, 10.1016/j.anbehav.2020.04.003, 164, (73-82), (2020).
        • Accounting for space and uncertainty in real‐time location system‐derived contact networks, Ecology and Evolution, 10.1002/ece3.6225, 10, 11, (4702-4715), (2020).
        • Consistent sociality but flexible social associations across temporal and spatial foraging contexts in a colonial breeder, Ecology Letters, 10.1111/ele.13507, 23, 7, (1085-1096), (2020).
        • Movement‐mediated community assembly and coexistence, Biological Reviews, 10.1111/brv.12600, 95, 4, (1073-1096), (2020).
        • Minding your own business: low pair cohesion in a territorial, monogamous mammal, Animal Behaviour, 10.1016/j.anbehav.2020.05.008, 166, (119-128), (2020).
        • The ecology of individual differences empirically applied to space-use and movement tactics, The American Naturalist, 10.1086/708721, (2020).
        • Social interactions in striped hyena inferred from camera trap data: is it more social than previously thought?, Current Zoology, 10.1093/cz/zoaa003, (2020).
        • Trends and perspectives on the use of animal social network analysis in behavioural ecology: a bibliometric approach, Animal Behaviour, 10.1016/j.anbehav.2019.01.010, 149, (77-87), (2019).
        • The use of multilayer network analysis in animal behaviour, Animal Behaviour, 10.1016/j.anbehav.2018.12.016, 149, (7-22), (2019).
        • Space use and social association in a gregarious ungulate: Testing the conspecific attraction and resource dispersion hypotheses, Ecology and Evolution, 10.1002/ece3.5071, 9, 9, (5133-5145), (2019).
        • Giraffe (Giraffa camelopardalis) social networks in areas of contrasting human activity and lion density, Ethology, 10.1111/eth.12923, 125, 10, (702-715), (2019).
        • Estimating interactions between individuals from concurrent animal movements, Methods in Ecology and Evolution, 10.1111/2041-210X.13235, 10, 8, (1234-1245), (2019).
        • Conducting social network analysis with animal telemetry data: Applications and methods using spatsoc, Methods in Ecology and Evolution, 10.1111/2041-210X.13215, 10, 8, (1203-1211), (2019).
        • The role of habitat configuration in shaping social structure: a gap in studies of animal social complexity, Behavioral Ecology and Sociobiology, 10.1007/s00265-018-2602-7, 73, 1, (2019).
        • When the winners are the losers: Invasive alien bird species outcompete the native winners in the biotic homogenization process, Biological Conservation, 10.1016/j.biocon.2019.108314, (108314), (2019).
        • Presence of kin-biased social associations in a lizard with no parental care: the eastern water dragon (Intellagama lesueurii), Behavioral Ecology, 10.1093/beheco/arz093, (2019).
        • Individual variation in the social plasticity of water dragons, The American Naturalist, 10.1086/704089, (2019).
        • Placing the effects of demography on networks in ecological context: a comment on Shizuka and Johnson, Behavioral Ecology, 10.1093/beheco/arz113, (2019).
        • The Influence of Loud Calls on Intergroup Spacing Mechanism in Black Howler Monkeys (Alouatta pigra), International Journal of Primatology, 10.1007/s10764-019-00121-x, (2019).
        • A mechanistic theory of personality‐dependent movement behaviour based on dynamic energy budgets, Ecology Letters, 10.1111/ele.13187, 22, 2, (213-232), (2018).
        • Advances from the nexus of animal behaviour and pathogen transmission: new directions and opportunities using contact networks, Behaviour, 10.1163/1568539X-00003507, 155, 7-9, (567-583), (2018).
        • Where should we meet? Mapping social network interactions of sleepy lizards shows sex-dependent social network structure, Animal Behaviour, 10.1016/j.anbehav.2017.11.001, 136, (207-215), (2018).
        • Integrating social networks, animal personalities, movement ecology and parasites: a framework with examples from a lizard, Animal Behaviour, 10.1016/j.anbehav.2017.09.008, 136, (195-205), (2018).
        • Eastern water dragons use alternative social tactics at different local densities, Behavioral Ecology and Sociobiology, 10.1007/s00265-018-2563-x, 72, 9, (2018).
        • Spatial Orientation and Time: Methods, Reference Module in Life Sciences, 10.1016/B978-0-12-809633-8.90090-6, (2018).
        • Resource landscapes explain contrasting patterns of aggregation and site fidelity by red knots at two wintering sites, Movement Ecology, 10.1186/s40462-018-0142-4, 6, 1, (2018).
        • Transmission on empirical dynamic contact networks is influenced by data processing decisions, Epidemics, 10.1016/j.epidem.2018.08.003, (2018).
        • Going through the motions: incorporating movement analyses into disease research, Ecology Letters, 10.1111/ele.12917, 21, 4, (588-604), (2018).
        • Network Structure Inference, A Survey, ACM Computing Surveys, 10.1145/3154524, 51, 2, (1-39), (2018).
        • The ecology of movement and behaviour: a saturated tripartite network for describing animal contacts, Proceedings of the Royal Society B: Biological Sciences, 10.1098/rspb.2018.0670, 285, 1887, (20180670), (2018).
        • Split between two worlds: automated sensing reveals links between above- and belowground social networks in a free-living mammal, Philosophical Transactions of the Royal Society B: Biological Sciences, 10.1098/rstb.2017.0249, 373, 1753, (20170249), (2018).
        • Endure your parasites: Sleepy Lizard ( Tiliqua rugosa ) movement is not affected by their ectoparasites , Canadian Journal of Zoology, 10.1139/cjz-2017-0352, (1309-1316), (2018).
        • An individual‐based model of ectotherm movement integrating metabolic and microclimatic constraints, Methods in Ecology and Evolution, 10.1111/2041-210X.12909, 9, 3, (472-489), (2017).
        • Analysing animal social network dynamics: the potential of stochastic actor‐oriented models, Journal of Animal Ecology, 10.1111/1365-2656.12630, 86, 2, (202-212), (2017).
        • An efficient method for sorting and quantifying individual social traits based on group‐level behaviour, Methods in Ecology and Evolution, 10.1111/2041-210X.12813, 8, 12, (1735-1744), (2017).
        • A guide to null models for animal social network analysis, Methods in Ecology and Evolution, 10.1111/2041-210X.12772, 8, 10, (1309-1320), (2017).
        • Why Is Social Behavior Rare in Reptiles? Lessons From Sleepy Lizards, , 10.1016/bs.asb.2017.02.001, (1-26), (2017).
        • Spatial organization and interactions of harvester ants during foraging activity, Journal of The Royal Society Interface, 10.1098/rsif.2017.0413, 14, 135, (20170413), (2017).
        • Does detection range matter for inferring social networks in a benthic shark using acoustic telemetry?, Royal Society Open Science, 10.1098/rsos.170485, 4, 9, (170485), (2017).
        • A framework for the identification of long-term social avoidance in longitudinal datasets, Royal Society Open Science, 10.1098/rsos.170641, 4, 8, (170641), (2017).
        • What's your move? Movement as a link between personality and spatial dynamics in animal populations, Ecology Letters, 10.1111/ele.12708, 20, 1, (3-18), (2016).
        • Current directions in animal social networks, Current Opinion in Behavioral Sciences, 10.1016/j.cobeha.2016.09.001, 12, (52-58), (2016).
        • Inferring animal social networks and leadership: applications for passive monitoring arrays, Journal of The Royal Society Interface, 10.1098/rsif.2016.0676, 13, 124, (20160676), (2016).