The exercise this week focuses on sensitivity analysis of the model we created last week according to Brown et al. (2005). We will utilize a parameter sweep to assess the importance of various parameters on the global value of average nearest neighbor distance (NND). In this model it is important to recognize that agent state variables are influenced by parameters and the degree of influence is what leads to emergent patterns in NND. Thus defining the role of state variables and parameters in the context of this model is fundamental to understanding the results of this sensitivity analysis.
A variable is a property of an entity. This entity can be either a cell or an agent, but it is some attribute which houses a value for each entity. Those entities are said to “own” this property in NetLogo. They can have numerical or string values. An example from the Brown et al. (2005) model is the cell property “status” which can be “empty”, “home”, “attraction” or “center”.
Parameters are some input to the processing of the model that may be able to vary, but is not a property of either the space (“world” in NetLogo) or the entities. These are often related to the stochastic elements of the model, as in this example where the preferences which are input values to the calculation of cell variables “aesthetic quality”, “service distance” and “utility”.
The parameters included in the Brown et al. (2005) model of development patterns interact in several important ways. These interactions make parsing the relative importance of the various parameters an interesting endeavor. In order to address the parameter space of the model we have chosen NND as an important metric of the spatiality of development. By focusing on the average distance between agents on the landscape, we can capture a portion of the difference between resulting spatial patterns and a random distribution. With respect to nnd we conducted a sensitivity analysis on the parameter space to identify the drivers of spatial patterning at the end of sufficiently long model runs. The model tests we conducted in two parts: a core analysis and an n_test interrogation. The core analysis consists of two instances. The first (S1) is all possible combinations of service_distance_preference (SDP), aesthetic_quality_preference (AQP) and neighborhood_density_preference (NDP) from 0 to 1 at increments of 0.5 resulting in 270 model runs. Max homes was set to 300 and n_test =16. The second (S2) is the set but with increments of 0.2, maximum number of homes = 500 and n_test = 100. These higher numbers for n_test and max_homes in S2 were meant to allow stochasticity to play a role, while still developing a rigorous framework for understanding the interactions between the core parameters. As a result, each agent was given the choice of a 1% subset of the landscape and the model runs proceed until 5% of the landscape was filled.
I interrogated the n_test parameter on a smaller scale, with 10 runs at each of 11 positions from 1 to 101 at intervals of 10 (Figure 1). This result was very significant (F = 94.25, p=2e-16), and passed Bartlett’s homogeneity of variance test (K-squared = 58.4055, df = 10, p = 7.25e-09).

Figure 1: The pattern of NND with increasing n_test shows exceptionally strong sensitivity over the lower half of the range 1-101.
Upon reviewing the final results for the core analysis, I conclude that the n_test parameter is probably the most important parameter for controlling outcome in terms of NND. In theoretical terms this is consistent with the model process and structure. In order to maintain imperfect knowledge, bounded rational behavior is implemented through n_test. The number of cells, n_test, that each new resident has available to choose from are distributed randomly across the landscape. In a homogeneous space, the number of choices would be irrelevant. However, in a heterogeneous space – implemented here with the cell state variable utility – the view of the potential new resident is of great importance. The cells selected for n_test are immediately ranked according to utility and the highest is the location chosen by the new resident. This means that any differentiation will result in substantial clustering
Of the core parameters, there is substantial variability in the influence that each plays in determining outcome measured by NND. From the less comprehensive model run S1, we that DSP and NDP have significantly different means (p=4.31e-05 and 2e-16 respectively), however fail Bartlett’s test. AQP in contrast is not significant (p=0.3), but passes Bartlett’s test (p=0.03).
S1 Outputs
The more rigorous model run S2, reveals additional information based on decreased stochasticity representing an increase in agent knowledge, or a greater n_test, and greater temporal extent (max_homes = 500).
Response dens_pref :
Df Sum Sq Mean Sq F value Pr(>F)
nnd 1 4.801 4.8008 42.144 1.05e-10 ***
Residuals 2148 244.688 0.1139
—
Signif. codes:
0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
Response aes_pref :
Df Sum Sq Mean Sq F value Pr(>F)
nnd 1 7.858 7.8579 69.854 <2.2e-16 ***
Residuals 2148 241.630 0.1125
—
Signif. codes:
0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
Response serv_pref :
Df Sum Sq Mean Sq F value Pr(>F)
nnd 1 29.194 29.1943 284.66 <2.2e-16 ***
Residuals 2148 220.294 0.1026
—
Signif. codes:
0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
In S2, MANOVA (shown above, Figures 8, 9, 10), reports high significance and passes Bartlett’s tests in all cases. Moreover, visually, the patterns of S1 and S2 are maintained, but refined in S2. In general, higher DSP leads to greater NND because new service centers are created leading to expansion of the development. NDP increasing leads to NND decreasing as new residents favor close proximity to neighbors, but notably in S2 the effect is limited to the lowest end of the 0-1 spectrum (Figure 9). The enigmatic result for AQP in S1 (Figure 7) is clarified in S2 (Figure 10). Here we see again a substantial change at the lowest parameter settings – between 0 and 0.2 NND increases as the two attractors draw people to spatially separated areas, however as AQP increases that negative feed back to NND is reduced as the pattern of development is more quickly focused toward a single attractor at the expense of the other. Ultimately, it may be mostly a question of degree with respect to the least impactful parameter, but I think in S2 NDP is restricted because the level of path dependence which results from it doesn’t begin at the start of the model. The events during the first 20 runs (preceding the first new service center). NDP is implemented in the utility calculation as an exponent, thus the value of 0 is the most important value because it turns the neighborhood term into a 1. Subsequent increases in NDP essentially reduce the variance of model runs with respect to NND. While this is an important reality, which effectively narrows the potential range of outcomes without shifting the mean value, this seems to be a less important. This effect is altered in S1, in that when there is a smaller subsample to chose from, the rapidly increasing number of new residents and their associated influence on the landscape has a much more substantial effect (Figure 6). In S1, with less comprehensive agent information, AQP is likely the least important parameter due to the static nature of the aesthetic landscape. As model runs progress in early stages, the increasing number of service centers and new residents mean that increasing the preference for these kinds of amenities has a more important effect on the outcome – at least when model runs are ended at 300. This contrast between S1 and S2 reiterates the importance of n_test in setting up the model outcome.
S2 Outputs
If the new resident model agents are assumed meant to represent individual homes, the importance of nearest neighbor distance is an important measure of density. At the scale of a suburban development, this would translate into the average distance between houses and at the scale of a metropolitan area it might be more similar to the distance between development projects. This metric is likely important to most potential homeowners in a suburban development because it would roughly describe the size of individual yards as well as the visual connection to neighbors. In reality, it is likely certain populations strongly prefer a more secluded environment, which in this model would be represented by low neighborhood density preference. Other people likely have much stronger preference for proximity to shopping, work or schools and thus might be willing to compromise the relative density of human population in favor of some attraction or service center.
Two other descriptors of average relationship to the heterogeneous landscape which would be almost implied by the structure of the model could include average distance to service or average distance to attractor. These would likely be the most relevant additional statistics for this model, and would provide fundamentally different information about agent behavior. It seems likely that distance to service would be correlated with increased preference for service most directly, and attractor distance would be most correlated with aesthetic preference. However, as we have seen, aesthetic preference will increase spatial clustering of agents and service centers are automatically generated in the vicinity of every 20th agent, so there is reason to believe that distance to service would increase with aesthetic preference as well. Conversely, distance to attractor would not necessarily increase with service preference, because the landscape becomes less restricted and attractors do not auto-generate during model runs.
In brief summary, this model describes how individual level preferences interact with a heterogeneous landscape to produce system level patterns. By implementing bounded rational behavior through random subsets of the landscape and subjecting them to agent preferences, stochastic events result in ranges of likely outcomes based on preference and knowledge parameters. Even slight preferences produce path dependence through attractive locations, the services created by dense development, or stability of close proximity to neighbors. These preferences produce feedback to new residents and clustered patterns which are spatially associated with the initial conditions effecting those preferences.








