Use of affinity analysis to guide habitat restoration and enhancement for the imperiled delta smelt

Habitat restoration efforts in the upper San Francisco Estuary, including the Sacramento–San Joaquin Delta, California, move forward, despite a paucity of information on the environmental requirements of many targeted species. The endemic delta smelt Hypomesus transpacificus, protected under the federal Endangered Species Act, is a primary focus of those efforts despite uncertainties regarding many aspects of its relationship with the estuary’s physical and biotic resources. Here we use time-series data from 4 trawl surveys and data on environmental attributes collected from throughout the delta smelt’s distribution to identify ranges of conditions acceptable to delta smelt for each of 5 environmental attributes: water-body type, temperature, turbidity, salinity, and prey availability. Low turbidity and elevated water temperatures render a large portion of the estuary seasonally unsuitable for delta smelt. Within areas in which water quality is suitable, patterns of delta smelt occurrences indicate that habitat is found in subregions where channels of intermediate depth adjoin shallow water. In certain subregions, conditions are inadequate for at least one of the environmental attributes for periods up to several months. We suggest a habitat-restoration strategy that can achieve adequate habitat conditions for delta smelt regardless of through-Delta flow levels, and which can be carried out at a number of locations, but not necessarily the same locations, during each life stage.


INTRODUCTION
It is a common understanding among conservation planners that the need for reliable knowledge re garding the habitat requirements of imperiled species frequently outstrips available relevant data (Ka reiva et al. 1998, Johnson et al. 1999, Reed et al. 2006. Planning for species with particularly narrow distributions, low abundances, and cryptic life stages and behaviors is often challenged by the few observations linking them to their habitats. For many species, descriptions of habitat requirements are inferred from species occurrence data, combined with supposition regarding resource requirements. That information base for conservation planning is inadequate for the task. But how then do resource managers employ limited data to draw inferences regarding resource requirements of endangered and threatened species in order to identify and characterize their habitats and guide resource management and habitat restoration? Importantly, how can data on a species' distribution and co-occurring environmental conditions be mobilized into reliable knowledge that can be used to assure that limited resources for conservation efforts are availed to management actions that actually benefit targeted species? We answer those questions with a case study of the imperiled delta smelt Hypomesus transpacificus. We describe an analytic approach that draws from available survey data on delta smelt and the dynamic and degraded estuarine ecosystem that supports it. The diminutive delta smelt's ecological relationships are obscured under the turbid waters of the upper San Francisco Estuary. Accordingly, the identity of its *Corresponding author: dennisdanielmurphy@gmail.com habitat and the essential resources and the environmental conditions that that habitat provides have been the subject of surmise, rather than informed by data. Almost 3 decades after its listing as a threatened species under the federal Endangered Species Act, a limited understanding of essential habitat attributes of the imperiled delta smelt has contri buted to strident disagreement regarding management actions necessary to protect the species, culminating in serial litigation involving federal and state governments, public water agencies, agricultural interests, environmental organizations, and other concerned stakeholders. Conservation planners intend to restore and enhance delta smelt habitat in order to bolster fish numbers and enhance the likelihood of its persistence. Meeting that objective is inhibited by an ab sence of relevant information -the delta smelt's actual numbers can only be speculated upon (see Bennett 2005, Kimmerer 2008, Newman 2008, Kimmerer et al. 2009), its patterns of dispersal are the subject of ongoing debate , Murphy & Hamilton 2013, Hobbs et al. 2019, and the causes of its imperilment appear to be many (e.g. Feyrer et al. 2007, Nobriga et al. 2008, Grimaldo et al. 2009, Winder & Jassby 2011. A just-released biological opinion from the US Fish and Wildlife Service (USFWS 2019) calls for restoration of delta smelt habitat that is projected to cost hundreds of millions of dollars over decades. Yet what habitat restoration actions should be carried out, where, and how they might be prioritized is uncertain (National Research Council 2011).
The purpose of this study is to draw inferences from publicly available survey data on delta smelt and data concurrently gathered on environmental factors that appear to contribute to the quality of its habitat. Sommer & Mejia (2013) have provided a general description of delta smelt habitat. We ex pand and resolve that information base, providing more clarity on certain environmental attribute ranges that are suitable and unsuitable for delta smelt and extending the quantitative analysis to all life stages at spatially meaningful scales. Other investigators have considered the roles of salinity, turbidity, and temperature in determining the distribution of delta smelt in the low-salinity zone of the estuary (Feyrer et al. 2007, Nobriga et al. 2008, Manly et al. 2015. Multiple multivariate analyses indicate that an array of environmental factors may contribute to determining delta smelt numbers -reductions in turbidity and the increases in the volume of water exports in winter months (Thomson et al. 2010), water temperature in the summer (Mac Nally et al. 2010), prey density along with effects from density dependence, predators, temperature in the late spring and early summer, and entrainment (Maunder & Deriso 2011), and stock, entrainment, water temperature, prey densities, and predation from April through June (Miller et al. 2012). While these studies identify a number of attributes of delta smelt habitat, and the physical and biotic resource conditions that may contribute to determining habitat extent and quality, these previous investigations were deficient in neither geographically subdividing the upper estuary, nor apportioning the life stages of delta smelt.
To assess the importance of individual habitat attributes to delta smelt, we applied habitat affinity analysis, adapting the approach of Guay et al. (2000), who developed preference curves for juvenile Atlantic salmon for several environmental factors by comparing the percentage utilization by the fish of areas with certain habitat attributes with the percent availability of those areas. Here we draw on agencygenerated conceptual models (IEP MAST 2015) that depict hypothesized, inferred, and established relationships between delta smelt and environmental variables. We identify candidate environmental attributes that appear to contribute to the extent and quality of habitat for delta smelt. We then use affinity analyses, in which we compare the frequency of delta smelt co-occurrence with range segments of physical and biotic conditions to infer associations between environmental attributes and the distribution of delta smelt at each of its life stages. Having identified important habitat attributes, we are able to identify circumstances where environmental factors are frequently inadequate, providing essential guidance in the selection and prioritization of locations for habitat restoration projects.

APPROACH AND METHODS
The San Francisco Estuary is the largest of its kind along the US Pacific Coast. The upper estuary ( Fig. 1) including the Sacramento-San Joaquin Delta, the confluence of rivers that drain nearly 40% of California's surface area (van Geen & Luoma 1999). The upper estuary is highly altered from its pre-settlement physiognomy, existing now as a network of mostly fortified waterways surrounding a patchwork of sub sided islands behind earthen levees. The extensive marshlands that previously dominated the estuary and the floodplains that surrounded it have largely been replaced by cultivated agriculture. The upper estu-ary supports a limited assemblage of native fishes; some are resident, some are anadromous transients, and several are endemic, notably the federally protected delta smelt. But delta smelt and the rest of the native fishes now exist in communities dominated by non-native competitors and predators, supported by a highly altered food web and local shortages of essential habitat-defining environmental features and resources.
The California Department of Fish and Wildlife conducts multiple surveys of estuarine fishes and species that occupy lower trophic levels, returns from which include delta smelt in samples that span its annual life cycle. Surveys include the 20 mm Survey, Summer Townet Survey (STN), Fall Midwater Trawl (FMWT), and Spring Ko diak Trawl, which sample extensive areas of the upper Estuary and historically collected delta smelt in meaningful numbers (www. dfg. ca. gov/ delta/ data). The me thods for these surveys have been documented previously (Moyle et al. 1992, USFWS 2004, Bennett 2005. The varying strengths and weaknesses of several of these surveys as population assessment tools for delta smelt have been described by Bennett (2005) and sampling biases in the surveys for delta smelt and other species have been explored by Latour (2016). We used data from these publicly available fish surveys, delineating life stages as depicted in Table 1, to assess the distribution in local densities of delta smelt. The time period represented for each life stage reflects the months when that life stage is most abundant.

Candidate habitat attributes
Environmental attributes that have been observed or surmised to contribute to habitat quality for estuarine fish include turbidity, salinity, temperature, dissolved oxygen, pH, aquatic vegetation, prey density, water depth, substrate composition, and water-body type (see Pardue 1983, Stier & Crance 1985, Weinstein 1986, Brown 2000. Previous studies of delta smelt indicate that water temperature has an influence on spawning (Wang 1986 used 1995−2011 1987−2011 1995−2011 1987−2011 1987−2011 2002−2011 2002−2011 Grimaldo et al. 2004, Bennett 2005, embryo survival (Moyle 2002, Mager et al. 2004, available habitat during the summer (Nobriga et al. 2008), and adult survival (Swanson et al. 2000), and is a key element of the bio-energetics of the fish (Rose et al. 2013). Hieb & Fleming (1999) found delta smelt across a near estuary-wide range of salinity conditions. It has been asserted that delta smelt prefer turbid water, perhaps for successful feeding and because it may reduce susceptibility to predation (Baskerville-Bridges et al. 2004, Mager et al. 2004). Investigators have described the calanoid copepod prey that support delta smelt (Nobriga 1998, IEP MAST 2015. The fish moves along the shoal−channel interface during flood tides and the shoreline during ebb tides (Bennett & Burau 2015) and has been described as frequenting shoals adjacent to deeper channels (Moyle 2002), with an assumption that emergent wetlands contribute to productivity at the base of the food web that supports the delta smelt. Other studies have recognized the potential importance of fish access to wetlands and floodplains (see Lindberg & Marzuola 1993, McIvor et al. 1999, Hobbs et al. 2006. Moyle et al. (1992) and Bennett (2005) have indicated that spawning likely occurs near estuary and river shorelines and adjoining sloughs. Substrate composition may be important in determining spawning habitat (Moyle 2002). McGowan (1998) found that areas inhabited by the invasive water-weed Egeria densa are not typically inhabited by native fishes in the estuary, including delta smelt, and areas supporting higher concentrations of submerged aquatic vegetation of all types are generally associated with low abundance of delta smelt (Sommer & Mejia 2013). Lehman et al. (2010) documented low delta smelt abundances in areas subject to episodic blooms by the toxic blue-green alga Microcystis. From these sources, we have generated a list of candidate environmental attributes for consideration in habitat affinity analyses for delta smelt (Table 2).

Covariate specification
We divided the upper Estuary into 10 subregions on the basis of landscape and ecological differences, flow dynamics, the distribution of delta smelt, and the presence of monitoring stations (Fig. 1). We found insufficient data to allow the inclusion of some variables in the affinity analyses -we were unable to obtain suitable data in time series or covering the full geographic range of delta smelt for dissolved oxygen, pH, contaminants, predation pressure, aquatic vegetation, or presence of Microcystis. For variables for which sufficient data exist, we aggregated those data from individual monitoring stations, of which there were approximately 120 in the FMWT and approximately 40 in other surveys, either as data that were taken along with fish samples (temperature, salinity, and turbidity), or as geographic and bathymetric data drawn from areas adjacent to those stations (depth) by averaging station data within a subregion. Data on other covariates were only available or applicable at the subregional scale (water-body type, prey availability, and predation pressure). The resulting attributes available for analysis include: turbidity as Secchi depth; salinity as electrical conductivity (EC) in microsiemens (μS) cm −1 ; water temperature as ºC; water body type as bay, river, or channel; depth as average depth within 1 km of station; and prey density as carbon weights derived from the number of calanoid copepods in μgC m −3 at zooplankton stations. Channel depth and water-body type were combined. In order to assess the influence of environmental factors that operate to determine delta smelt occurrences, we considered habitat associations at subregional spatial scales (Fig. 1).

Affinity analyses
Affinity analyses compare the availability of an environmental resource or physical characteristic with the use of that resource by or co-occurrence with that physical characteristic of a target species,  allowing for 'preferences' for resource conditions to be ascertained (Lechowicz 1982, Grost et al. 1990, Monaco et al. 1998, Cardona 2006. Affinity analysis provides a means of correcting sampling bias by relating species occurrences to the availability of a re source, habitat characteristic, or environmental attribute. For example, if 70% of the individuals of a certain fish species in a survey are sampled from sites located in deep water, and 50% of the survey sites are in deep-water circumstances, that would indicate that the fish has an affinity for deep water -'use' exceeds 'availability'. However, if 70% of fish are sampled in a survey with 90% of its sites located in deep water, that would indicate that the fish has an affinity for shallower-water circumstances, or an aversion to deep water -'availability' exceeds 'use'. When little is known about a species, an affinity analysis can offer insights into the nature of the relationship between an environmental attribute and the target species, depending on whether the species exhibits an affinity with, or aversion to, the environmental attribute, and whether an affinity, if found, is strong or weak. It does not require the a priori specification of a functional ecological relationship; therefore, it does not presuppose the nature of a relationship that may exist. Graphical depictions of the re sults can assist in identifying threshold phenomena and other non-linear relationships that may be inherent to the fish−factor interaction. Care should be taken to consider collinearity between variables ( Table S2 in the Supplement at www. int-res. com/ articles/ suppl/ n043 p103 _ supp. pdf).
In conducting the affinity analyses for biotic and abiotic attributes, we divided the full range of data for each attribute into 10 segments. The delineations of the 1st and 10th segments were set at the attribute values associated with the 5th and 95th percentile of the cumulative distribution of the fish. The intermediate 8 segments were delineated so that each segment had approximately the same availability. The discrete nature of most attributes prevented the segments from having exact equal availability. For water-body type, the segments were the categories of each type of water body. We compared the percentage of fish observed in each segment to the percentage of times each segment was sampled. That is, for each 2 mo period during which a life stage was most abundant, we used pivot tables (in Microsoft Excel) to sum the number of delta smelt individuals recorded and the number of observations in each attribute segment. (For example, of 3127 subjuveniles caught in surveys in May 1995, 950 were caught in Secchi depth segment 3: 20 to 25 cm. In that same month, 175 surveys were conducted, 28 of which occurred in waters falling in the range of Secchi depth segment 3.) We then converted these to a percentage value for each month (in our example a use of 30% versus an availability of 16%) and averaged them across years. For each attribute segment, we calculated the percentage of times each segment was sampled, average use of each segment, average difference between the 2, and standard deviations of each difference to determine a 90% confidence interval.
We present affinity analyses as graphs for each life stage showing the average percentage of delta smelt in each attribute segment (use) compared to the average percentage of times each attribute segment was sampled (availability). We display the difference between resource availability and its use, along with the 90% confidence interval surrounding the difference. The difference between use and availability was considered statistically significant if the difference exceeded the critical 't level' at the 90% level of confidence (Hamburg 1970). This is depicted graphically when the 90% confidence interval does not intersect with the zero line (see the right axis in the column graphs in Fig. 2). We describe a range of affinity conditions for delta smelt ranging from 'never observed' to 'strong affinity' (where use is statistically greater than availability) and associate those with a corresponding range of environmental conditions (Table 3).

Derivation of affinity functions
Suitability indices are hypothetical models that are developed from a review and synthesis of existing information on use of a resource by a species. The relationship is scaled to produce an index of habitat quality between 0 (low-quality habitat) and 1 (highquality habitat) (see Weinstein 1986). Guay et al. (2000) utilized affinity studies to develop attribute indices for juvenile Atlantic salmon, which they referred to as 'preference indexes'. We largely follow that approach by employing average use-to-availability ratios across months and years for each attribute segment and life stage to assess affinities for a range of environmental factors for delta smelt. In contrast with the approach of Guay and colleagues, we did not rescale the use-to-availability ratio once it was calculated. Rescaling affinity scores results in inferences being lost -numbers greater than 1 reflecting adequate conditions and numbers less than 1 reflecting inadequate conditions. We therefore use the term 'affinity index' to distinguish the unscaled use-to-availability ratios from the preference index values calculated by Guay et al. (2000), which range from 0 to 1. We recognize that a weakness of affinity analyses is that the expressed affinity by species to a specific environmental condition is relative -individuals may actually inhabit a location because conditions there are 'better' than at alternative locations, not necessarily because the location offers environmental conditions that might be described as suitable or even adequate. When this phenomenon occurs, increased 'noise' in the data results in increased variability in use-to-availability ratios, making statistical significance harder to detect.
Calculating the ratio of use to availability for each segment of each attribute shows patterns of affinity to which curves can be fitted. Curves fitted over the range of a habitat attribute we term 'affinity functions'. We fitted a cubic-spline curve through calculated affinity index points using XLStat (Addinsoft 2020). By their nature, affinity functions should mono tonically increase to a maximum, and if an optimal level is reached and surpassed, then monotonically decrease. It is not biologically reasonable that fish have discontinuous suitable ranges for environmental attributes; therefore, points that caused the fitted spline to diverge from monotonic were averaged with nearby points, and outliers -anomalous points not consistent with prevailing patterns -were not considered. In a few cases where different curves may be fit, preference was given to the curves which were most biologically plausible. We report the R 2 value to describe the fit of each curve to the points derived from the affinity analysis.
We used affinity analyses to distinguish suitable conditions from adequate conditions, and unsuitable conditions from inadequate conditions, these being statistical distinctions (see Table 3). We used affinity functions to delineate the range of adequate condi-tions because the affinity functions provided interpolation between data points.

Identification and prioritization of restoration actions
Because delta smelt distribution and environmental conditions change with through-Delta flows, we calculated the frequency with which each attribute was in an inadequate range for each subregion and flow condition. For this analysis, we divided through-Delta flows estimated at the Delta's western boundary, net of tidal effects, into deciles. We then looked to the attributes that are most frequently observed in inadequate ranges in any subregion and considered flow condition as a guide to circumstances in which habitat quality could be improved.
The relative ease with which environmental attributes in the upper Estuary can be manipulated or managed varies considerably. Water temperature is most strongly influenced by ambient air temperature, although relief from high temperatures may be provided by creating more riparian shading, providing more tidal marshland that can lead to night-time cooling, or creating areas with deep, cooler water. While a trend for decreasing turbidity in the Delta has been recognized for some time, a practical solution remains elusive. Turbidity might be enhanced in some subregions by providing more turbulent flows across floodplains and increasing sediment loading into the Delta from upstream. Salinity management and prey enhancement are currently more accessible management tools. The salinity field can be managed subregionally through control-gate operations and regionally through reservoir releases; sophisticated models exist to assess the effects of such actions on the salinity field (www.rmanet.com/ services/numerical-modeling/rma-bay-delta-model/), although a recent study suggests that moving the salinity field bay-ward may deplete prey throughout the areas occupied by the fish (Hamilton et al. 2020). Regarding prey availability, the trophic linkages in the food web for delta smelt are well established (Kimmerer & Orsi 1996, Nobriga 1998. The relationship between wetlands and primary productivity in adjacent waters (see Alpine & Cloern 1992) has prompted recognition that ecosystem rehabilitation at the land−estuary interface can enhance the 'production, transport, and transformation of organic  . Although 'the production and distribution of phytoplankton can be highly variable within and between nearby habitats of the same type, due to phytoplankton sources, sinks, and transport' (Lucas et al. 2002), the restoration of tidal wetlands and floodplains has been identified as the primary means for enhancing habitat for delta smelt (USFWS 2019). Based on the frequency of attributes in inadequate circumstances, the ease with which they may be corrected, and delta smelt's affinity for specific subregions, we present preliminary suggestions for prioritizing habitat restoration that is spatially, temporally, and hydrologically specific.

RESULTS
The affinity analyses for subregions of the upper estuary showed significant differences that were generally consistent between delta smelt life stages (Table 4,  niles, juveniles and pre-spawning adults demonstrating greater affinity for the South Suisun and Napa River subregions during periods of high flow (Table 5).

Affinity analyses for habitat attributes
Delta smelt associations with 5 environmental attributes of the estuary for 5 life stages during 6 sampling periods are presented as ranges of habitat conditions in Table 6, as histograms in Fig. 2 (and in Figs. S2−S6), and comparative affinity functions in Fig. 3. These environmental attributes -turbidity, salinity, temperature, prey availa bility and waterbody type -are features of, or environmental conditions that contribute to, habitat quality for delta smelt. The delta smelt life stages show varying affinities for environmental attribute conditions, where utilization (the height of the red column in the histograms) exceeds that of the attribute's availability (the height of the blue column with which it is paired) (Fig. 2). Delta smelt are averse to environmental circumstances in which that relationship is reversed. Life stage-specific affinities and aversions for the suite of environmental attribute conditions can be summed to shape a multi-dimensional description of delta smelt habitat.
Subjuvenile delta smelt are sampled while dispersing from shallow spawning areas to the open water areas in which they then feed and grow. Having less-developed swimming abilities, they do not express associations with environmental attributes as closely as they appear to do in later life stages. Subjuveniles express a strong affinity for moderate turbidity (Secchi depth of 25 to 39 cm) and strong aversion to clearer waters (Secchi depths above 49 cm, Fig. S3c). Water temperatures are rarely in the ranges that could induce stress in this early life stage, but sub juveniles seem to have a strong aversion to waters in excess of 21.9°C (Fig. S4c). Subjuveniles are frequently found in near-freshwater conditions typical of spawning areas with suitable conditions ranging from 250 to 1380 μS cm −1 ; unsuitable conditions occur when salinities are greater than 4000 μS cm −1 . (Fig. S5c). Strong affinity exists for prey density above 8300 μgC m −3 (Fig. S6c), perhaps reflecting poor delta smelt survival in areas with lower prey densities, and in deep river circumstances (Fig. S2c). Juvenile delta smelt show strong affinity for turbid water less than 31 cm Secchi depth and strong aversion above 44 cm (Fig. S3d,e). They exhibit a strong aversion to water greater than 22ºC and are never observed in circumstances exceeding 24ºC (Fig. S4d,e). Juveniles appear more tolerant of salinity as the summer progresses, with suitable conditions ranging from 470 to 5330 μS cm −1 and strong aversion being expressed below 150 and above 7800 μS cm −1 in June− July (Fig. S5d). By July− August, strong aversion is not expressed until salinity exceeds 15 000 μS cm −1 (Fig. S5e). Juveniles do not express a strong affinity for areas with dense prey but express a strong aversion to areas with little prey -less than 890 μgC m −3 early in the summer, and less than 850 μgC m −3 later in the summer (Fig. S6d,e). A strong affinity for shallow-water bays is apparent (Fig. S2d). The primary area where these conditions co-occur is in Grizzly Bay, a large area of shallow water into which (presumably) nutrient-rich water from Montezuma Slough and Suisun Slough empty. A strong affinity also exists for rivers of intermediate depth (4−8 m). Subadult delta smelt tolerate somewhat clearer water than earlier stages (Fig. 3b). Strong aversion to clear water is not expressed until Secchi depths exceed 64 cm in September−October and 75 cm in November−December (Fig. S3f,g). Strong aversion to water temperatures occurs above 20.6°C in September−October and subadult delta smelt do not inhabit water exceeding 21.7°C (Fig. S4f). Suitable salinity 112 Fig. 2. Affinity analyses and functions for (a) water clarity, (b) water temperature, (c) salinity, and (d) prey availability for subjuvenile delta smelt sampled by the 20 mm Survey in May and June 1995-2011. Similar graphical displays for juveniles, subadults, and pre-spawning adults are available in Figs. S2−S6 in the Supplement. Differences between the paired columns are depicted with green dots bracketed by a 90% confidence interval and referenced by the right axis. In the bottom graphs, blue dots depict differences between use and availability in range segments that were significantly different from zero. Red dots depict non-significance conditions range from 860 to 5500 μS cm −1 in September−October and 960 to 7110 μS cm −1 in November−December (Fig. S5f,g). Subadults express a strong affinity for prey densities above 6840 μgC m −3 in September− October, this number dropping to 1750 μgC m −3 in November− December as water 113 Fig. 3. Comparison of affinity functions by environmental attribute and delta smelt life stage. Life stage, survey months, and survey are denoted in the legend. These graphs are intended to convey general relationships rather than precise ones. Habitat attribute values that have corresponding affinity index values greater than 1 indicate adequate conditions. See Table 1 for additional information cools and bioenergetic demands decrease (Fig. S6f,g). Subadults express a strong affinity for rivers of intermediate depths (4−8 m) (Fig. S2f,g). Pre-spawning adult delta smelt are presumably taken while dispersing to spawning areas (Murphy & Hamilton 2013). They show strong affinity for water with less than 28 cm Secchi depth (Figs. 3b & S3a), but show no influence of water temperature on their distribution (Fig. S4a). Pre-spawning adults are relatively insensitive to salinity (Figs. 3d & S5a). Prespawning adults express an affinity for locations with prey availability above 560 μgC m −3 , lower than observed for previous life stages (Figs. 3f & S6a). They show affinity for the channels of intermediate depth (4−8 m), but not for the bays or rivers (Fig. S2a).
Spawning adults sampled in trawl surveys number the fewest from all life stages. Since the reduction in abundance from pre-spawning to spawning adults is far greater than would be expected due to natural attrition, it is likely that the spawning adults are moving away from the monitoring sites. Spawning adults express a strong aversion to clear water (greater than 53 cm Secchi depth) (Fig. S3b). Temperature seems to play no apparent role in the distribution of spawning delta smelt (Fig. S4b). They exhibit a very narrow range of suitable salinity, 500 to 730 μS cm −1 , suggesting a need to move to fresh water to spawn (Figs. 3d & S5b). Spawning adults still express strong aversion to areas with low food densities, in this case areas with prey less than 730 μgC m −3 (Fig. S6b). They demonstrate a strong affinity for channels of intermediate depths (4−8 m) (Fig. S2b).
Comparing between life stages, affinity functions for water clarity for subjuveniles and juveniles are similar (Fig. 3a) -adequate conditions are waters with Secchi depths generally less than 40 cm. Subadults are observed in clearer water with adequate ranges less than 60 cm (Fig. 3b). Pre-spawning adults appear the most sensitive of all life stages to turbidity, with adequate ranges being less than 35 cm. Adequate ranges for spawning adults occur at Secchi depths less than 55 cm. Both pre-spawning adults and spawning adults display an aversion to very turbid water (Secchi depths less than 13 to 17 cm). Delta smelt show no affinity for water temperatures during the cooler months of October to April (Fig. 3g). In the warmer months, delta smelt display acclimatization to warmer water with adequate conditions occurring at less than 22.5°C. Delta smelt display decreasing sensitivity to salinity with age. For subjuveniles, adequate conditions occur in waters with salinity less than 2500 μS cm −1 . This increases to 6300 μS cm −1 for juveniles, 8700 μS cm −1 for subadults in September and October, and 10000 μS cm −1 for pre-spawning adults; however, spawning adults appear to seek fresh water. Adequate salinity conditions for spawning adults occur at less than 1300 μS cm −1 . All life stages display aversion to very fresh water. All life stages also display aversion to low densities of prey, the threshold varying with bioenergetic demands. Adequate prey densities range from 300 μgC m −3 for prespawning adults to 6000 μgC m −3 for subjuveniles.

Identification of inadequate conditions and management implications
The results in Table 5 indicate that there are specific subregions in which delta smelt are likely to be found under varying flow conditions. But affinity analyses showed that areas that are frequently occupied by delta smelt are not occupied at certain times due to inadequate attribute conditions, indicating that delta smelt will move from favored areas when conditions become inadequate. We report the frequency with which attributes are inadequate for delta smelt by life stage, subregion, and flow conditions (see Table 8 and Table S1 in the Supplement).
For example, Table 7 shows that salinity was in inadequate ranges in Suisun Marsh (the water was too saline) in 100% of the times it was sampled in the July-August period when flow was in the first decile (lowest 10% of May to July flow conditions). Zeros indicate that no attribute was in an inadequate range. This table should be interpreted to depict general circumstances when attributes are frequently, infrequently, or never in unsuitable ranges. Table S1 provides this information for each attribute individually. For example, water clarity is frequently inadequate in the Confluence and Lower Rivers subregions from January through July. Water temperature can be inadequate in numerous subregions in July under nearly any flow conditions. Salinity is frequently inadequate in the Suisun Bay and Suisun Marsh during low flow conditions in all months. And prey availability appears inadequate in multiple subregions under most flow conditions from September through April.
From Table S1, we identified a minimum set of core subregions and the habitat attributes that could be modified to assure that at least the North Delta and 1 other subregion would provide adequate conditions for delta smelt under any hydrologic circumstance ( Table 8). The North Delta was suggested as a priority subregion for restoration due to the year-round presence of delta smelt in that location (recorded on trawl surveys). Other subregions were identified due to low frequency of inadequate conditions for water temperature and turbidity -attributes that are considered difficult to modify through management actions. Zero values in Table 8 indicate that under a wide range of flow conditions and across months, no directed management actions are necessary to elevate delta smelt habitat quality. Habitat could be enhanced during lower-flow periods by lowering salinity in Suisun Marsh from March through December and improving prey availability in the North Delta and Suisun Marsh. During higher-flow periods, habitat can be enhanced by improving salinity in Suisun Marsh from November through June and in North Delta in June through December, and by improving prey availability in those areas yearround. Turbidity and water temperature are occasionally in inadequate ranges, and directed research would be required to determine whether management actions could be developed to address those specific circumstances.

DISCUSSION
The affinity analyses performed here confirm 2 reasonable assumptions regarding relationships between delta smelt and their habitats that are foundational to designing restoration projects and management actions, and prioritizing implementation of them. The analyses confirm that habitat requirements for delta smelt vary by life stage and that the upper San Francisco Estuary exhibits diverse and fluctuating environmental conditions that influence habitat quality. Ecosystem variability manifests as a constantly shifting geographic mosaic of habitat qua lity that confronts maturing delta smelt, presenting a moving and challenging target for conservation management. The results presented in Table 8 indicate delta smelt are challenged by months during which no subregion in the estuary offers environmental conditions that are in adequate ranges for all environmental factors. Such circumstances set the stage for bottlenecks in regionwide habitat quality; circumstances, for example, wherein food and turbidity may be inadequate for a period in their life cycle, forcing delta smelt to forage for long durations in places where they are vulnerable to predation, with consequential and substantial impacts on mortality rates.
The first objective of a habitat restoration strategy should be to identify a set of locations where habitat conditions are adequate for delta smelt throughout their life cycle, regardless of Delta through-flow volumes, including the extremes of flood and drought. Priority for environmental restoration efforts should be given to locations where delta smelt are most frequently found, and where directed actions can effectively and efficiently elevate all relevant habitat The development of a restoration strategy incorporating these design features begins with an understanding of the distribution of the target species in space and time. That fundamental step is essential to identifying the spatial, temporal, and hydrodynamic circumstances that are inadequate to support delta smelt, and which should therefore be excluded as targets of restoration planning. Five subregions were frequently occupied under nearly all flow conditions: Suisun Marsh, North Suisun, the Confluence, Lower Rivers, and North Delta. To these subregions could be added East Delta in the spring during low-flow conditions, and the Napa River and South Suisun in  Table 8. Frequency (%) with which attribute circumstances are less than adequate for delta smelt in the five frequently populated subregions under higher-flow and lower-flow circumstances. Positive numbers show the frequency (%) with which conditions exceed adequate environmental-factor ranges. Negative numbers show the frequency (%) with which conditions occur in lower-than-adequate ranges. Red shading indicates temperature or clarity conditions that are frequently inadequate (more than 20% of the years for which data are available). Green shading indicates conditions that are frequently adequate (inadequate in less than 20% of those years). Yellow shading indicates the lowest frequency of inadequate conditions for temperature or clarity across regions during a 2-month period when all regions experience conditions that are frequently inadequate. Subregions that should be considered a higher priority for restoration are those with attribute circumstances outlined with boxes: the North Delta, because of the year-round presence of delta smelt, and other subregions where conditions might be readily enhanced through restoration efforts. na: data are not available the spring and summer during high flows. Within that limited geographic range, the environmental management challenge is to provide a suite of biotic and abiotic conditions that allow the species to thrive. By working from the results in Tables 8 and S1, it is possible to articulate relevant management actions within this focal geographic range. To illustrate how specific restoration objectives might be identified, consider the January−February period. On the one hand, water clarity conditions are frequently inadequate in the Confluence and Lower Rivers, making these subregions poor targets for habitat restoration to enhance occupancy by delta smelt during that period. On the other hand, Suisun Marsh rarely has inadequate conditions in January and February and habitat in that subregion might be enhanced by improving prey availability and salinity. If successful, this would make Suisun Marsh suitable for delta smelt in January and February under all flow conditions except the 2 lowest flow deciles. Salinity conditions in North Suisun could be improved through management actions during lower flow conditions. Therefore, while not achieving circumstances where conditions are adequate under all flow regimes, the conditions for delta smelt would be substantially improved by focusing management actions on the locations where specific attributes are just infrequently inadequate. A preliminary set of subregions that could be high priority for habitat restoration are identified in Table 8; primarily the North Delta and Suisun Marsh, subregions physiographically and ecologically most similar to the historic upper San Francisco Estuary. Such a spatiotemporally resolved restoration strategy requires that delta smelt be able to disperse successfully to find suitable conditions.
If the first objective of a habitat restoration strategy is implemented successfully, sensible biogeographic design rules can follow. In conservation management, it is generally recognized that restoration efforts should be focused in and around core sanctuaries. Qualitatively, the first phase may only seek to restore conditions to a level that is 'adequate', while later phases may seek a higher standard -conditions that are 'suitable' (see Table 6). Quantitatively, later pha ses may target adjoining subregions, or perhaps more distant subregions if connectivity can be achieved.
The results of the affinity analyses presented here appear to have immediate application. The proposal to restore habitat for delta smelt is advanced in a biological opinion produced by the USFWS (2019), which determined that ongoing water export opera-tions from the estuary by state and federal pumping projects adversely impact critical habitat for delta smelt. While recognizing that a broad array of physical and biotic factors contributes to delta smelt habitat, the USFWS chose to use the location of the lowsalinity zone in the estuary as a surrogate measure for the extent and quality of habitat for delta smelt. That assumed relationship asserts that habitat for delta smelt becomes increasingly available at higher freshwater outflow levels, when the low-salinity zone in the estuary is at its greatest areal extent. The assumptions underlying that relationship have been shown to not be valid (Murphy & Weiland 2019) and evidence that some delta smelt freely move between higher-salinity and lower-salinity situations in the upper estuary has been documented (Hobbs et al. 2019). The analyses presented here indicate that delta smelt have no affinity for South Suisun (Table 4) and that while salinity conditions in highflow circumstances are frequently limiting in North Suisun, prey availability is more frequently limiting there (Table 8), such that improving salinity conditions and not prey availability will not improve habitat quality. A management action proposed by USFWS, which increases outflow through the Delta under prescribed conditions, generally diminishes prey availability for delta smelt in much of the estuary, exacerbating the problem (Kimmerer et al. 2019, Hamilton et al. 2020. The absence of well-resolved environmental variables, beyond the ones used in the habitat affinity analyses carried out here, has implications for restoration planning. Geographic patterns of predation on delta smelt are not known, but areas to which delta smelt show a strong affinity appear to host higher densities of non-native fish species, many of them documented to prey on delta smelt (Feyrer 2004, Schreier et al. 2016. Cohen & Carlton (1998) contend that in the San Francisco estuary, up to 97% of the total number of organisms and 99% of the biomass are alien invasive species, leading Grimaldo et al. (2004) to opine that management efforts should 'create or restore wetlands that only flood during winter and spring, the period when native fishes spawn and recruit into the estuary'. Certainly, restoration actions that might benefit predators over the imperiled delta smelt should be avoided.
The use of affinity analyses provides a number of advantages when developing restoration strategies. Affinity analyses can provide quantitative ranges for suitable and unsuitable environmental conditions by life stage, which can be used to set restoration goals. While recognizing noise in the sampling and analysis creates uncertainty, the articulation of inadequate attribute ranges allows conservation managers to identify and target specific places and times (subregions, months, and flow conditions) when environmental attributes are in inadequate ranges. Resources do not need to be expended in circumstances where the conditions of all attributes are adequate. Beyond correcting specific circumstances, the use of affinity analyses facilitates the development of restoration strategies that confront the varying habitat needs of the targeted species across its life stages. Affinity analyses can be used to develop 'affinity functions' that are neither linear nor symmetrical. This finding offers evidence to support the concept that optimal ranges of environmental attributes affect the distribution and abundance of species, and that considering those attribute ranges is essential to successful habitat restoration. Affinity functions can depict species responsiveness to circumstances, similar to results from more traditional techniques. In our application here, the shapes of the response functions for the June−July period, for example, were similar to the GAMS results attained previously by Sommer & Mejia (2013).
Five factors related to habitat quality -turbidity, temperature, salinity, prey availability, and certain physical water-body characteristics -while alone not competent to characterize the habitat space available to delta smelt, contribute to defining the geographic spaces suitable for them. The ability for management actions to influence those habitat factors varies by attribute and subregion. A restoration strategy should seek to achieve conditions that are adequate for delta smelt, regardless of outflow levels, at a minimum number of locations, but not necessarily the same location, in every month. Later stages in habitat restoration would further improve habitat quality for delta smelt in those areas and expand the geographical extent of adequate conditions. All restoration projects require direct engagement of resources which are frequently limited. The inability to recognize when and where circumstances are inadequate for a target species results in the re direction of resources away from beneficial appli cations and has both ecological and economic consequences. The affinity analysis approach to conservation planning offers a remedy.