Animals and instrumentation

The Galápagos National Park Service approved of and granted the research permits for this work. During August, 2014, adult females (N=15) caring for chicks on the coast of Darwin Bay, Genovesa Island, Galápagos, Ecuador (0°19'5.57"N, 89°57'1.23"W) were caught by hand on their nest at night. The chick was covered to keep it warm and safe while its mother was instrumented. Using isoflurane anaesthesia and aseptic methods16, for each cerebral hemisphere, EEG sensors were placed on the dura overlying the anterior (A) and posterior (P) hyperpallium, a structure that forms a pronounced bulge in the cranium of frigatebirds (Fig. 1b; for a CT scan of a similar skull see, www.digimorph.org/specimens/Fregata_magnificens/); the sensors were 8 mm apart along the AP axis, spanning the most pronounced portion of the cranial bulge, and 4 mm from the midline (Fig. 1b). A fifth sensor was placed laterally on the left hemisphere for the electrical ground. The gold-plated, round-tipped (0.5 mm diameter) sensors were secured with a small amount of dental acrylic cured with an ultraviolet light (Clearfil SE Bond, Kuraray Noritake Dental, Japan and Tetric EvoFlow, Ivoclar Vivadent AG, Schaan, Liechtenstein) and connected to a flexible, insulated spring wire (no. 276-0146-001; DSI, St. Paul, MN). The wires were soldered to a data logger (Neurologger 2A; www.evolocus.com, see also www.vyssotski.ch/neurologger2) which included a 3.6 V lithium battery (Saft LS-14250; www.saftbatteries.com) and a three-axis accelerometer (LIS302DLH; STMicro-electronics). The logger was glued (Hystoacryl, Aesculap AG, Germany and Pattex, Repair Gel, Henkel AG & Co. KGaA, Germany) to the skin and feathers just posterior to the naso-frontal hinge (Fig. 1b). The logger was configured to record bipolar EEGs from the left and right hemispheres, and acceleration in the three cardinal directions continuously at 200 Hz for up to 10 days. A GPS data logger (i-gotU, GT-600; www.i-gotu.com) configured to record position every 5 min was attached to the back feathers with gaffer tape (tesa, no. 4671; www.tesatape.com). The total weight (55 g) of the equipment was 4.0% of the birds' weight (1366.79±24.09 g, s.e.m.). Fourteen of the 15 birds were recaptured 7.79±0.49 d (s.e.m.; range, 5.37–10.45 d) later, after returning from at least one foraging trip. In nine of the birds, we obtained recordings (16.40±3.33 h, s.e.m., in duration; Supplementary Fig. 9g) after they returned to the nest to evaluate sleep on land. At the end of the study, the equipment was removed under anaesthesia and the birds were released. On release, the birds resumed nesting behaviour indistinguishable from that observed in undisturbed birds. Finally, to validate our analysis of the flight trajectories in great frigatebirds, we used data recorded from two magnificent frigatebirds (Fregata magnificens) in a pilot study conducted in the French Guiana using a GPS data logger (GiPSy-2, www.technosmart.eu) with a 1 Hz sampling rate combined with a 3D acceleration logger (25 Hz rate; AXY-1, www.technosmart.eu; Fig. 1d,e).

Sleep scoring and EEG analysis

During flight, all days with stable EEGs were scored for time spent awake, and in SWS and REM sleep using 4 s epochs and REMLogic software (Natus Medical, Pleasanton, California)16. All recordings after returning to land were also scored, including the short landings between two flights observed in birds 1 and 5 (Supplementary Figs 1 and 3). A bout of a given state was defined as one or more epochs of that state uninterrupted by a single epoch of another state. The bout durations for wake, SWS, REM sleep and the overall amount of time spent in each state were based on all scored days. The spectral analysis of the EEG focused on a night with comparatively large amounts of sleep and high signal quality (see Supplementary Figs 1–8). For each state, all 4 s artifact free epochs were analysed with the fast Fourier transform (0.25 Hz bins) applied to Hamming-windowed data. SWA and gamma power were estimated from Fourier coefficients taken for ranges 0.75–4.5 and 30–80 Hz, respectively. Medians of SWA and gamma power were used for statistical comparisons. Quartiles for group medians shown in Fig. 4b and Supplementary Figs 14b and 15b are estimated by bootstrap. Interhemispheric asymmetries in SWA and gamma, and their relationship with the mode of flight (Fig. 3d,e), were based on the night with large amounts of sleep. In addition, SWS-related SWA was calculated for the last night of flight to detect potential changes in sleep intensity across the flight (Supplementary Fig. 15b).

Accelerometry analysis

The accelerometer recordings revealed two predominant patterns during flight (Fig. 2a). Flapping flight was characterized by large sinusoidal oscillations (≈2.5 Hz) in the heave and surge axes corresponding to individual wing beats. In contrast, during gliding and soaring flight, the three axes were largely flat or showed slow oscillations likely reflecting a combination of fine manoeuvres and respiratory movements (see expanded view for SWS in Fig. 2a). When gliding and soaring during the day, small, frequent and rapid horizontal movements of the head were superimposed on these slow oscillations. Flight was occasionally interrupted by a rapid decrease in acceleration along the heave axis, corresponding to the bird dropping, presumably due to momentary folding of the wings (Supplementary Movie 4). Finally, bouts of high-frequency activity occurred infrequently in all axes simultaneously, likely reflecting preening, as observed in birds flying over the colony and while on the nest.

Previous studies12,13,26 and our own observations (Fig. 1d), show that frigatebirds exhibit two major flight trajectories; rising in circles (soaring) and straight gliding down. In addition to identifying flapping flight, the accelerometer was useful for discriminating circular from straight flight (Fig. 1e). During both types of flight the absolute air-referenced flight speed averaged over significant time intervals (>4 s) is constant (Fig. 1e). Thus, the tangential (co-directed with the speed vector) acceleration is zero in both flight modes. When the animal flies straight the total acceleration felt by the accelerometer is produced only by the gravity vector g (standard gravity, 1g 0 =9.80665, m s−2). However, during circular flight additional centripetal (radial) acceleration, a r =V2/R (V, speed; R, radius of the trajectory) is added to the acceleration of gravity: . As rotation lies approximately in the horizontal plane, the two acceleration vectors are orthogonal to each other and total acceleration, . Thus, to determine whether the trajectory is straight or not, it is sufficient to measure total acceleration, low-pass filter it to remove the influence of wing flapping and compute radial acceleration from this equation. Radial acceleration above 0.175g 0 corresponded to circling flight (Fig. 3, Supplementary Fig. 16). Total acceleration in circling flight was 1.057±0.003g 0 and radial acceleration was −0.340±0.009g 0 (s.e.m.; see Supplementary Table 1 for values for individual birds). The bank (wing) angle during soaring was measured as arccos(g/a tot ) and was 18.75±0.48° (s.e.m.). However, for our EEG analysis it was also important to know whether the bird was rotating to the right or to the left. This information was obtained by measuring radial acceleration with the accelerometer mounted on the bird’s head with one axis (that is, sway) directed laterally. Because frigatebirds keep their heads straight during both flight modes, we were able to determine radial acceleration directly from the accelerometer without additional transformations. However, to confirm this claim and to increase the accuracy of the radial acceleration measurements we also performed computations without this assumption. The accelerometer was attached to the bird's head in a way such that one axis was orthogonal to the tangential plain of the bird skull and another was directed laterally. Projection of total acceleration on to the tangential plain of the bird skull clearly shows three clusters corresponding to straight and circling flight, with turning to the left and right (see data from one example bird in Supplementary Fig. 16a). To simplify this analysis, we rotated the axes of the head-fixed coordinate system to have one axis directed to the ground during straight flight; however, in the recording examples shown in Figs 2 and 3, Supplementary Fig. 13, acceleration is shown in the original axes of the accelerometer. The following analysis shows that the skull surface tangential plane deviated by 29.86±0.68° (s.e.m.) from the horizon (see Supplementary Table 1; see also Fig. 1a). As a first step we down-sampled the acceleration data to 25 Hz (from original 200 Hz) to decrease computation time. We then filtered out high frequencies by applying a low-pass finite impulse response filter (0.1 Hz; span 40 s). The input data were processed both in the forward and reverse directions and the resulting sequence had precisely zero-phase distortion and doubled filter order. Then, we computed principle components (PCs) in 3D space without mean subtraction. The first PC pointed in the direction of the gravity vector, the second—in the lateral (radial) direction, and the third—in the direction of the speed vector. Because we found that accuracy of the PCs determination can be affected by outliers, mainly due to episodes when the bird drops down with acceleration in the direction of the first PC <0.95g 0 , we excluded such points and recomputed the PCs again. In the horizontal plain of the second and the third PCs (Supplementary Fig. 16b), clusters corresponding to rotation to the left and right were aligned relative to the coordinate axes. The best separation was observed along the second PC corresponding to sway acceleration. The vertical lines drawn at sway accelerations ±0.175g 0 reliably separate the three clusters in all birds. Because we wanted to compute rotations of the head relative to straight flight, we repeated the PC analysis, but for points representing straight flight only. Coordinates of the first PC gave the direction to the ground during straight flight. The angle between this direction and skull surface normal is the skull angle shown in Supplementary Table 1. We rotated the coordinate system a second time to have one axis in the direction of the first PC (Supplementary Fig. 17). In this head-fixed coordinate system, during circling flight, the absolute value of lateral (sway) acceleration was 0.321±0.008g 0 (s.e.m.), acceleration in the direction of the flight (surge) was 0.028±0.005g 0 and vertical (heave) acceleration was 1.006±0.001g 0 (see Supplementary Table 1). Assuming zero tangential acceleration as before, we computed the angle of the head turn in circling flight (2.137±0.184°, s.e.m.) relative to straight flight and the direction of the axes over which the turn was performed (right–left: 0.626±0.096°, beak–tail: 0.521±0.111°, down–up: −0.209±0.033°, signs are valid for the case when the animal turns left, but absolute values represent averaged quantities for left and right turns taken together, see Supplementary Table 1). To simplify interpretation of the head turn we computed angular deviations of the head-fixed vector pointing upwards in the lateral (right–left) and anterior–posterior (beak–tail) directions. These deviations were 1.033±0.252° and 1.444±0.233° (signs correspond to the left turn as before). As shown in the table, bank angle (wings-to-horizon) was computed with the assumption that total acceleration was orthogonal to the plane of the wings. This assumption was verified by placing accelerometers on the backs of two magnificent frigatebirds together with the GPS logger in a pilot study (Supplementary Fig. 18). In these two birds, total acceleration during circling flight was 1.053 and 1.067g 0 . Standard deviations of sway acceleration were 0.013 and 0.016g 0 , and standard deviations of surge acceleration were 0.033 and 0.036g 0, respectively. Thus, the standard deviation of the total acceleration vector in the lateral direction was 0.71° and 0.85° and in the anterior–posterior direction it was 1.80° and 1.38°. Taking the 95% confident border as a more conservative estimate, we obtained 1.45° and 1.67° for sway and 3.60° and 2.81° for surge. These angles are much smaller than the angle of the wing plane to the horizon (18.32° and 20.41°). Thus, our assumption about orthogonality of the plane of the wings to total acceleration is correct.

Detection of wing flaps and drops

Wing flaps and drops were detected by analysing the absolute values of the acceleration vectors recorded by the accelerometer. As a first step, acceleration was down-sampled to 50 Hz to decrease computation time. Then the signal was band-pass filtered 0.25–5 Hz. The finite impulse response filter with an 8 s span was applied in forward and reverse directions to ensure a zero time shift. Deviations in acceleration below −0.4g 0 were selected as potential flaps and drops. Flaps and drops were separated from noise and sorted by the shape of acceleration signal around these events (±0.64 s). The 64-point fragments of the record centred around the detected acceleration minima were sorted using wavelets and a superparamagnetic clustering algorithm37 (WaveClus 2.0 package for Matlab) in birds 1 and 2. After validating the classification algorithm and cluster matching in two birds, the recorded fragments from the remaining birds were sorted using a faster and simpler nearest neighbour algorithm (computing and comparing distances from non-classified elements to the members of the clusters already classified in bird 1). The average shapes of acceleration around flaps, drops and noise are shown in Supplementary Fig. 19a. Flaps produce pseudo-periodical deviations in total acceleration with negative and positive deviations of approximately similar magnitude. These almost sinusoidal deviations are produced by regular up–down wing movements. Contrary to flaps, drops are characterized by a strong negative deviation followed by a slow positive compensation. They are produced by momentary folding of one or both of the wings (see Supplementary Movie 4). Noise is characterized by smaller deviations around the zero time point and on average has a symmetrical shape (relative to the zero time point). The distribution densities of the maximal deviation of acceleration (at zero time) shown in Supplementary Fig. 19b demonstrate that flaps can be readily separated from noise by simply selecting a threshold around 0.6g 0 . However, separation of drops from flaps and noise required information about the signal shape. To estimate the duration of flapping flight we summed the ±0.35 s interval around flap detection points.

Wind speed analysis

Wind information (absolute value and direction at the birds' location) was obtained from the Movebank database ( www.movebank.org). The database provides wind speeds for altitudes >100 m. For lower altitudes between 10 and 100 m, wind speed was computed from the wind data at 10 m using the equation W=W 10 (h/h 10 )α, where W is the wind speed at the desired altitude h; W 10 the known wind speed at altitude h 10 =10 m over mean sea level; and α the Hellmann exponent. In this study, the Hellmann exponent (α=0.03958) was estimated from the average ratio of wind speed at altitudes 100–150 m (given by the database) to W 10 . Because the altitudes given by GPS are not precise enough to be used for calculating wind speed at altitudes <10 m, the value W 10 was taken as an estimate of wind speed.

Statistical analysis

For comparisons between flight and land N=9, whereas for in-flight comparisons N=14. Unless stated otherwise, reported values are the mean±s.e.m. Paired Student’s t-tests (two-tailed) were used in most cases. Quantities expressed as a per cent were first normalized using a Fisher transformation. For the time course of SWA and the different types of SWS on land, the analysis was restricted to birds with at least 10 h of recording time (N=7), and only the first 10–12 h were used for this analysis. For the analysis of the relationship between sway acceleration and EEG asymmetry (Fig. 3), the mean of the sway values >0.175g 0 (to left) and <−0.175g 0 (to right) for individual birds were used.

Data availability

The authors declare that the data supporting the findings of this study are available within the article and its Supplementary Information Files, or from the corresponding authors upon request.