The colorful representation of orientation preference maps in primary visual cortex has become iconic. However, the standard representation is misleading because it uses a color mapping to indicate orientations based on the HSV (hue, saturation, value) color space, for which important perceptual features such as brightness, and not just hue, vary among orientations. This means that some orientations stand out more than others, conveying a distorted visual impression. This is particularly problematic for visualizing subtle biases caused by slight overrepresentation of some orientations due to, for example, stripe rearing. We show that displaying orientation maps with a color mapping based on a slightly modified version of the HCL (hue, chroma, lightness) color space, so that primarily only hue varies between orientations, leads to a more balanced visual impression. This makes it easier to perceive the true structure of this seminal example of functional brain architecture.
Mammalian primary visual cortex (V1) contains neurons that respond best to edges or bars at particular orientations (Hubel & Wiesel, 1977). In species such as cats, ferrets, monkeys, and humans, nearby neurons in V1 tend to respond to similar orientations, leading to orientation preference (OP) maps in V1 with a complex structure (Blasdel & Salama, 1986; Bonhoeffer & Grinvald, 1991; Hübener, Shoham, Grinvald, & Bonhoeffer, 1997; see Figure 2, top left). This structure is sensitive to the statistics of the visual environment during the critical period; for instance, raising a cat in an environment consisting of stripes of mostly one orientation leads to an overrepresentation of that orientation in the OP map (Blakemore & Cooper, 1970; Sengpiel, Stawinski, & Bonhoeffer, 1999; Tanaka, Ribot, Imamura, & Tani, 2006; Hunt et al., 2009; Hughes et al., 2014). The structure, development, and plasticity of OP maps have provided a seminal case study for important issues in developmental, systems, and computational neuroscience (Espinosa & Stryker, 2012; Kaschube, 2014).
Since orientation preference is a periodic variable, OP maps are usually displayed graphically with a periodic color mapping. Pictures such as these have become iconic, providing eye-catching images sometimes used to advertise neuroscience more generally. However, the conventional color mapping is suboptimal from the point of view of visually assessing structural information about OP maps. This is because such pictures have almost always used a color mapping based on the HSV (hue, saturation, value) color space, which has highly nonuniform luminance across different hues (see Figure 1). It is well established that the various properties of color—hue, saturation, and brightness—bias human observers’ perception of the size of an area, though the precise effects of each of these dimensions are complex and not well understood. Generally warmer colors such as red and yellow appear larger than cooler colors such as blue and green (Tedford, Bergquist, & Flynn, 1977; Cleveland & McGill, 1983), though the effect is diminished when using colors with low saturation (Cleveland & McGill, 1983). The perceived size of shapes is affected by brightness, but the effect seems to be defined by the difference between the colors of an area and its surroundings rather than the area’s absolute properties (Oyama, 1962; Nakano, Tanabe, Mori, Ikegami, & Fujita, 2005).
Such biases are especially problematic for studying issues in OP maps such as coverage uniformity (Swindale, Shoham, Grinvald, Bonhoeffer, & Hübener, 2000), and in particular for assessing overrepresentation of orientations caused by natural scene statistics (Coppola, White, Fitzpatrick, & Purves, 1998), or in response to altered visual experience such as stripe rearing (Sengpiel et al., 1999). While quantitative analyses of map structure do not rely on human visual perception, the visualization of data in a fair and unbiased manner is still critical. It is therefore important to find visual representations of OP maps that best reflect the actual stucture of the data rather than the idiosyncrasies of how humans perceive color. Here we propose a color mapping based on a modification of HCL (hue, chroma, lightness) color space for displaying OP maps and illustrate its advantages, particularly for representing the effects of stripe rearing.
2 Color Spaces
There are many ways to define colors mathematically, and a model for how a collection of numbers defines a color is known as a color model (Fairchild, 2013). The best-known is RGB, where each color is defined by a triplet of values, , specifying how much red, green, and blue light, respectively, must be emitted to form the color. Such a model, combined with a reference absolute color space (the details of which we will ignore here), defines a color space, of which the most widely used is sRGB. As an alternative to sRGB, a family of color spaces more closely based on how humans perceive color was defined by the International Commission on Illumination (Commission internationale de l’éclairage, CIE). In particular, the LUV (or CIE 1976 ()) color space is close to perceptually uniform: a small movement in the space corresponds to a small change in the perceived qualities of the color (Fairchild, 2013). One advantage of this space is that as one moves through the color space in the hue dimension, only hue changes, not other perceptual properties of the color.
An important property of colors is luminance, an objective measure of the radiance of a color based on a typical human observer. We take luminance to mean relative luminance Y, which is luminance relative to the luminance of a reference white point. For an sRGB color , we calculate this as , where (derived by converting from sRGB to CIE XYZ space and taking the Y coordinate, which corresponds to relative luminance; Schanda, 2007). This formula was used to calculate luminance for all the color mappings we discuss below. Brightness is the term given to the subjective version of luminance (i.e., how much light an area appears to emit in a particular situation), which increases monotonically but not linearly with luminance (Purves, Williams, Nundy, & Lotto, 2004).
For visualizing periodic functions, the most common choice for a color mapping uses the HSV space (which is not standardized; we used the Matlab implementation, originally defined by Smith, 1978). Here saturation (colorfulness) and value (a kind of brightness) are held constant, and the hue H is cycled through 360 to obtain a periodic color mapping of hue (see Figure 1A, HSV annulus). Note that the value parameter is not the same as luminance or brightness, only a somewhat similar property, and so luminance and brightness vary considerably with hue while V is held constant.
An alternative choice is to use polar coordinates in the LUV color space described above, where, similar to HSV space, the color is specified by hue, chroma (colorfulness), and perceived lightness (similar to brightness) (Wyszecki & Stiles, 2000). This is commonly referred to as HCL (or CIE LChuv) space. As with HSV, the chroma and lightness are held constant while the hue H is cycled (see Figure 1A, HCL annulus). A notable difference between these two color mappings is that luminance is constant across hues for HCL, while it varies for HSV (see Figure 1B). (Note that the luminance shown in the figure is not exactly constant, as not all HCL colors can be represented in sRGB space. These were therefore corrected to be viewable on a computer monitor by bounding their RGB values to , which slightly modified their luminance.) This is important for data visualization, as the brightness of a color, especially a highly saturated one, can affect its perceived size.
3 Color Mappings for OP Maps
For demonstration purposes, we generated two artificial orientation preference maps: a standard map with a uniform orientation distribution and one with the 0 orientation overrepresented to a degree comparable to the higher end of that seen in empirical stripe-reared maps (Sengpiel et al., 1999; Hughes et al., 2014). These maps were generated by sampling from gaussian process priors (Macke, Gerwinn, White, Kaschube, & Bethge, 2011; Hughes et al., 2014), which is equivalent to convolving gaussian noise with a difference of gaussians filter to generate each vector component of a map. Orientation overrepresentation was generated by increasing the three parameters of overrepresentation used in Hughes et al. (2014). While these maps vary from empirical maps in some higher-order statistics (Erwin, Obermayer, & Schulten, 1995; Wolf & Geisel, 1998; Kaschube et al., 2010), they provide a conveniently simple way of constructing an artificial map with spatial structure representative of empirical maps. Note that orientation preference is periodic in 180 as parallel directions have the same orientation, and so our color mappings map the 360 of hue to the 180 of orientation.
While visually striking, standard HSV color mapping for displaying OP maps (see Figure 2, left column) has the obvious problem that the luminance of the different colors used is highly nonuniform. This can be seen directly in the third row of Figure 2, which shows the luminance of the OP map. This problem is avoided by using a color mapping based on HCL space (see Figure 2, middle column), which has constant luminance across hues. However, this introduces a different problem, which is that the lack of any luminance differences makes it difficult to perceive borders (Frome, Buck, & Boynton, 1981), and thus hard to see map structure. To achieve a compromise between equiluminance and border perception, we therefore introduce modulated HCL (mHCL). This is the same as HCL, except that instead of the chosen lightness L being held constant, L is a periodic function of hue H: . Here H is the hue in radians, L0 is the base lightness, and m is the modulation parameter, specifying the amplitude of the lightness variation (see Figure 1B). This allows luminance variations to be introduced in a smoothly controlled and systematic manner. Although it is not as visually striking, the perception of this map more accurately reflects the true underlying structure compared to the HSV map (see Figure 2, right columns).
The significance of this difference can be seen in Figure 3, which shows a map where one orientation is more strongly represented (as might be caused by, for example, stripe rearing). Assigning a particular hue to represent the 0 orientation is an arbitrary decision, and perception of map structure should therefore be insensitive to this choice, which is indicated by the bars at the top of the columns in Figure 3. However, this is clearly not the case for the HSV map (see Figure 3A): quite different map structures can often be perceived depending on which color represents the overrepresented orientation (e.g., focus on a small region at corresponding positions in each map, such as the top right-hand corner). In addition, the color assignment influences the qualitative assessment of degree of overrepresentation. While this perception is of course subjective, to us it appears that when green or red (second and third columns, respectively) is used for the overrepresented color, their areas appear much larger than when blue or purple is used (consistent with the psychophysical literature described earlier). This is less true for the mHCL representation (here ), where corresponding regions now appear more similar as the choice of hue for 0 is varied and the level of overrepresentation appears qualitatively more similar across the row (see Figure 3B).
We have created a Matlab GUI that displays the orientation preference maps shown here, with the user’s choice of color mapping (HSV, HCL, or mHCL) and color mapping parameters. The effects of color mapping choice can be clearly seen when this interface is used. The GUI as well as several Matlab functions for generating and using HCL and mHCL color mappings are available at http://github.com/nickjhughes/hclmat.
Visual neuroscientists have amassed a detailed understanding of how color and form perception interact. Here we have applied some of these lessons to optimize the visual representation of OP maps. In particular, we propose a color mapping for OP maps using a modified version of the HCL color space, which trades off luminance invariance against the ease of detecting borders. This trade-off depends on a modulation parameter that determines the strength of luminance modulation as a function of hue. This allows the representation of OP maps to be optimized to convey the properties of the map that are most important for the particular question under consideration.
There are alternative approaches to the problem of border perception, such as superimposing iso-orientation contour lines over the map or using only a small number of colors (e.g., four or eight) such that each iso-orientation domain is easier to perceive. However, one must choose the contour orientations or the range of orientations each color represents in these cases, and these choices may have an impact on the perception of the map. If these methods are used, the mHCL mapping can still be used as well and is a good solution when orientation is displayed purely as a color map.
Due to its cyclic hue, the HSV color mapping is commonly used for visualizing periodic data, and the perceptive biases we have discussed are likely to apply in many circumstances. Indeed, the color choices in heat map representations are known to affect perception (Gehlenborg & Wong, 2012). The HCL or mHCL mappings may therefore be more appropriate in many other contexts. The use of more perceptually uniform colors for use in graphs has been suggested previously (Ihaka, 2003). Our introduction of the mHCL scheme allows the application of this in situations where continuous color mappings are used and boundary perception is also important.
We thank Ross Ihaka for introducing us to the importance of color choices in data representation.