Python Return Continuous Strech of Numbers in a List
Depending on the type of imagery you're working with, there are a number of options for displaying and symbolizing it. Only symbology types that are valid for the data you've selected are presented. For example, you can display multispectral imagery using a three-band color composite—also known as an RGB composite—in which you use the bands available to highlight features of interest. You can also display the values along a color scheme to show the areas that are brighter than others. This is referred to as applying a stretch to a dataset. You can use the Classify and Discrete options to group continuous data into a limited number of groups. The Vector Field option allows you to display ocean and wind currents as arrows indicating magnitude and direction. This also works with a dataset that has vector (V) and unit vector (U) components.
Modify the appearance of an image layer
To change the appearance of an image layer, complete the following steps:
- Click the Symbology button, located on the Raster Layer, Mosaic Layer, or Image Service Layer tab.
The Symbology pane appears.
- Set the symbology parameters for the layer.
- Click the lower half of the Symbology button to access additional symbology options.
In the Symbology pane, you can fine-tune the parameters specific to the symbology type you selected. You can also select other layers from the Contents pane and, without closing the Symbology pane, apply the same symbology to them.
There are minor, yet distinct, differences between the options for symbolizing imagery. The RGB, Unique Values, Stretch, Colormap, Classify, Shaded Relief, and Discrete options accomplish similar adjustments but in different ways. Stretch is the classic color scheme option; it takes the range of all the values in the data and stretches it to fit within a data type range. For example, 8-bit data is stretched from 0 to 255. Unique Values is similar, except the colors are not continuous. This is appropriate for qualitative data such as land cover. The Discrete color scheme is continuous, as is Stretch, but you specify how many colors it uses to display the data with no legend in the Contents pane. The pixel values are then grouped accordingly. Classify is similar to Discrete, except it includes the distribution of values and groups the values into the number of breaks or colors you want to display. A color map is useful when you want to select a color for each pixel value. These can be saved, imported, and exported for use with other datasets. The Vector Field option allows you to display phenomena—such as currents—as arrows, or vectors, in which the direction of the arrow indicates the direction of the current, and the size of the arrow is related to the force of the current. Vector Field symbology can be applied to a dataset with a magnitude and direction or a U and V component.
Save symbology settings as a template
You can save symbology settings as a template in the Symbology pane and reuse them as custom functions that can be applied from the Raster Functions pane. This generates a template that contains the appropriate functions to replicate the symbology used to display the layer of a raster dataset, mosaic dataset, or image service. You can do the following with this template:
- Use it as a processing template for a mosaic dataset. Open the Raster Type properties, click the Functions tab, right-click a template in Processing Template, and click Load.
- Edit the function chain in a mosaic dataset or its items using the Edit Function Chain option from the layer context menu.
To save a template of symbology settings as a function that can be accessed from the Raster Functions pane, complete the following steps:
- Add a raster dataset, mosaic dataset, or image service to a map.
- Click the Symbology button on the Raster Layer, Mosaic Layer, or Image Service Layer tab.
- Modify the symbology, such as applying a stretch or using a different color scheme.
- Click the Options button in the Symbology pane and choose Export as raster function template.
- Provide a name for the template.
- Choose a Custom Category and Sub-Category value.
- Provide Description text, choose a Type value, and click OK.
RGB
The color model RGB stands for red, green, and blue. RGB symbology allows you to create composite images by loading multispectral bands into each channel (R, G, and B). The various band combinations can help highlight specific features on the image.
Primary symbology options
Under Band Combinations, select the bands you want to display as red, green, and blue. To obtain a natural-looking image, match the red image band with the red video display channel, green with green, and blue with blue. You can also create other composites that highlight how features respond to various parts of the electromagnetic spectrum. For example, load the near-infrared band into the red drop-down list, the red band into the green drop-down list, and the green band into the blue drop-down list. This creates a color infrared composite that uses the strong reflection of vegetation in the near-infrared band and displays areas of high vegetation as red. An alpha band acts as a transparency mask, providing a transparency value for each pixel. An alpha band can be turned on or off for multiple-band raster datasets rendered with the RGB Composite renderer.
Check the Invert check box to invert each band to create a negative image.
Use Stretch Type to define the range of values to display. This is often used to eliminate extreme high and low values that represent noise in imagery. When you choose one of the options from the Stretch Type drop-down list, the parameters that you set here are used. The following are the Stretch Type options:
- None—No stretch is applied to the layer, even if statistics exist. To display data other than 8-bit data, image values are linearly mapped between 0 and 255. None is a good choice if you want to examine absolute values in raster datasets.
- Minimum Maximum—A linear stretch is applied based on the output minimum and output maximum pixel values, which are used as the endpoints for the histogram. For example, in an 8-bit dataset, the minimum and maximum values may be 33 and 206. A linear stretch is used to distribute the values across 256 values, from 0 to 255. In this example, 33 is mapped to 0, 206 is mapped to 255, and the values between these endpoints are linearly distributed. This increases the ability to see differences in values throughout the dataset.
- Percent Clip—A percentage of the highest and lowest values are clipped and a linear stretch is applied to the remaining values across the available dynamic range of the data type. This reduces the effects of outliers in the datasets and enhances the remaining data.
- Standard Deviation—A linear stretch is applied between the values defined by the standard deviation (n) value. For example, if you define a standard deviation of 2, the values beyond the second standard deviation become 0 or 255, and the remaining values are linearly stretched between 0 and 255.
- Histogram Equalization—A nonlinear contrast stretch is applied in which the values are spread out throughout the bit depth range. This method is appropriate when there are many pixel values that are closely grouped.
- Histogram Specification—The histogram is loaded from an XML file. This allows you to edit the histogram in a piecewise fashion, in which you can assign a linear stretch to multiple ranges of values within the data.
- Custom—A custom stretch is applied. This allows you to edit the histogram in a piecewise fashion, in which you can assign a linear stretch to multiple ranges of values within the data. This is the set stretch type when you create a custom stretch of any kind.
- Esri—A sigmoidal stretch is applied, which makes it ideal for maintaining contrast in bright areas, such as an urban area surrounded by a desert.
Click the Histogram button to view the histogram distribution of the pixels, and use the Minimum Maximum, Percent Clip, and Standard Deviation stretch types to view the pixel distribution and interactively set the minimum and maximum input values. When you edit the histogram, the Histogram button is updated, indicating it has been edited. See Raster histogram stretching for more information about the Histogram page.
Adjust the Gamma setting of the imagery to highlight the contrast of moderate pixel values.
There are two subtabs on the Primary symbology tab :
- Statistics
- Mask
The Statistics tab is used to determine how to display the data. The Statistics drop-down menu contains the DRA (dynamic range adjustment), Dataset, and Custom options. When DRA is chosen, the statistics based on the current display extent are calculated as you zoom and pan the image. The Dataset option calculates the statistics for the entire dataset and uses those values regardless of the portion of the image that is displayed. You can also input your own statistics in the table using the Custom option. You can do this by importing the statistics from another dataset or importing an .xml file from the Options menu. When you're finished, you can save your custom statistics.
Use the Mask subtab to remove background values and set the NoData values. If you want to set the background value, you must do so for each band. Although these values are often the same for each band, they may change. Check the Display background value check box, provide the values that represent the background, and choose the background color. You can also choose a color for the NoData pixels. Click Apply to persist the changes.
RGB options
You can access the RGB options from the Options button at the top of the Symbology pane.
You can import a layer or a package to set the parameters.
You can save your symbology as a raster function template.
Unique Values
Unique Values symbology randomly assigns a color to each value in a dataset. This is often used with thematic data, such as land cover, for its limited number of categories. It can also be used with continuous data if you choose a gradient color scheme.
Primary symbology options
Field 1 specifies the field in the attribute table that is used to symbolize the unique values. Color scheme is used to quickly color each unique value. You can choose a color for each value if a preset color scheme is not appropriate for the data.
To choose a color for NoData pixels, set the NoData value. Transparency is usually used and is the default.
Advanced symbology options
On the Advanced symbol options tab , you can format the labels of category names. When you make changes here, they are automatically updated in the Contents pane.
Unique Values options
Access the Unique Values options using the Options button at the top of the Symbology pane.
You can import a layer or a package to set the parameters.
You can also import or export your color map settings.
You can save your symbology as a raster function template.
Stretch
Stretch symbology allows you to define the range of values to be displayed and apply a color ramp to those values.
Primary symbology options
The following are the Stretch options:
- Band—Selects the band to stretch in a multiband dataset.
- Invert—Inverts the color scheme to create a negative image.
- Edit min/max values—Allows you to edit the minimum and maximum values for the layer. This is only available for the Minimum Maximum stretch type.
- Label—Refers to the labels in the Contents pane.
- Stretch type—Defines the range of values to display.
- Histogram—Allows you to view the histogram distribution of the pixels and edit the histogram stretch for the Minimum Maximum, Percent Clip, and Standard Deviation stretch types. See Raster histogram stretching for more information about the Histogram page.
- Gamma—Controls the amount of contrast in moderate pixel values.
There are three subtabs on the Primary symbology tab :
- Statistics
- Mask
- Advanced Labeling
The Statistics tab is used to determine how to display the data. The Statistics drop-down menu contains the DRA (dynamic range adjustment), Dataset, and Custom options. When DRA is chosen, the statistics based on the current display extent are calculated as you zoom and pan the image. The Dataset option calculates the statistics for the entire dataset and uses those values regardless of the portion of the image that is displayed. You can also input your own statistics in the table using the Custom option. You can do this by importing the statistics from another dataset or importing an .xml file from the Options menu. When you're finished, you can save your custom statistics.
Use the Mask subtab to remove background values and set the NoData values. To set the background value, check the Display background value check box, provide the value that represent the background, and choose the background color. You can also choose a color for the NoData pixels. Click Apply to persist the changes.
Use the Advanced Labeling subtab to convey the stretched data that you are displaying. You can set custom labels and create custom color schemes. For more information about advanced labeling, see Use advanced labeling for a continuous raster dataset.
Advanced symbology options
On the Advanced symbol options tab , you can format the labels of category names. When you make changes here, they are automatically updated in the Contents pane.
Stretch options
You can access the Stretch options using the Options button at the top of the Symbology pane.
You can import a layer or a package to set the parameters.
You can save your symbology as a raster function template.
Colormap
Colormap symbology applies the color map associated with the raster.
Primary symbology options
Each label has an associated preset color. To change the color, you can import a color map or layer file.
To choose a color for NoData pixels, set the NoData value. Transparency is usually used and is the default.
Advanced symbology options
On the Advanced symbol options tab , you can format the labels of category names. When you make changes here, they are automatically updated in the Contents pane.
Colormap options
You can access the Colormap options using the Options button at the top of the Symbology pane.
You can import a layer or a package to set the parameters.
You can also import or export your color map settings.
You can save your symbology as a raster function template.
Classify
Classify symbology allows you to group pixels in a specified number of classes. You can then edit the break points between each class.
Primary symbology options
The Classify options are as follows:
- Field—Represents the values of the data.
- Normalization—Divides the values from the Field option by another attribute. There are also options for Percent of total and Log normalization techniques.
- Method—Specifies how the break points are calculated.
- Classes—Sets the number of groups to symbolize.
- Color scheme—Specifies the color ramp for displaying the data.
- Nodata—Specifies the color for displaying NoData values.
Use the table to make changes to individual groups, such as changing the color of a particular group of values or adjusting its range of values.
There are three subtabs on the Primary symbology tab :
- Classes
- Histogram
- Mask
The classes show the color and value ranges for each class. The value ranges can be adjusted with the preset methods. The upper value can be manually edited in the table or by adjusting the class breaks with a histogram.
The number of decimal places for the labels depends on the data type and the minimum and maximum values:
- If the data has only integer values, three decimal places are used for the labels.
- If the data has floating point values, and the minimum value is greater than 0.009, three decimal places are used for the labels.
- If the data has floating point values, and the values are between 0.009 and 0.000001, six decimal places are used for the labels.
- If the data has floating point values, and the minimum value is below 0.000001, scientific notation is used for the labels.
To quickly increase or decrease the number of significant digits or decimals, use the increase button and the decrease button .
To choose a color for NoData pixels, set the NoData value. Transparency is usually used and is the default.
Advanced symbology options
On the Advanced symbology options tab , you can format the labels of category names. You can also exclude values or set the sample size. Any values within the range set for the Exclude Values option are displayed as NoData. To estimate the statistics and resulting histogram, you can use a skip factor, which systematically samples pixels based on the number of rows and columns you want to skip. You can ignore values to adjust how the image is rendered by excluding those values from the distribution. When you make changes here, they are automatically updated in the Contents pane.
Classify options
You can access the Classify options using the Options button at the top of the Symbology pane.
You can import a layer or a package to set the parameters.
You can save your symbology as a raster function template.
Discrete
Discrete symbology displays a dataset using a specific number of colors. Each color represents the same value, and when the colors have all been used, it reuses the color scheme for the next set of values.
Primary symbology options
You can choose the color scheme and the number of values that the color scheme can accommodate each time it is used. A low number of colors means that only part of the color scheme can be used. A larger number means that there is less differentiation between the adjacent values.
To choose a color for NoData pixels, set the NoData value. Transparency is usually used and is the default.
Discrete options
You can access the Discrete options using the Options button at the top of the Symbology pane.
You can import a layer or a package to set the parameters.
You can save your symbology as a raster function template.
Shaded Relief
Shaded Relief symbology displays a color 3D representation of the terrain created by merging the images from the elevation-coded and hillshade methods.
Primary symbology options
The hillshade options allow you to customize the shaded relief parameters.
Use the Color scheme option to specify the color ramp for displaying the data.
Use the Hillshade Type option to control the illumination source for the hillshade.
- Traditional—Calculates hillshade from a single illumination direction. You can set the Azimuth and Altitude options to control the location of the light source.
- Multidirectional—Combines light from multiple sources to represent an enhanced visualization of the terrain.
The Azimuth value is the sun's relative position along the horizon (in degrees). This position is indicated by the angle of the sun measured clockwise from due north. An azimuth of 0 degrees indicates north, east is 90 degrees, south is 180 degrees, and west is 270 degrees.
The Altitude value is the sun's angle of elevation above the horizon and ranges from 0 to 90 degrees. A value of 0 degrees indicates that the sun is on the horizon; that is, it is on the same horizontal plane as the frame of reference. A value of 90 degrees indicates that the sun is directly overhead. The default is 45 degrees above the horizon.
The Scaling value dynamically changes the shaded relief rendering by adjusting the z-factor:
- None—No scaling is applied. This is ideal for a single raster dataset covering a local area. This is not recommended for worldwide datasets with large variations in elevation or multiscale maps, as it produces terrain relief with little variation at small scales.
- Adjusted—A nonlinear adjustment is applied using the default Pixel Size Power and Pixel Size Factor values, which accommodate a wide variety of altitude changes (scale) as the viewer zooms in and out. The Adjusted option is recommended when using a worldwide dataset.
The Z Factor value is a scaling factor used to convert the elevation values for two purposes:
- To convert the elevation units (such as meters or feet) to the horizontal coordinate units of the dataset, which may be feet, meters, or degrees
- To add vertical exaggeration for visual effect
The Pixel Size Power value accounts for the altitude changes (or scale) as the viewer zooms in and out on the map display. It is the exponent applied to the pixel size term in the equation that controls the rate at which the z-factor changes to avoid significant loss of relief. This parameter is only valid when the Scaling type is Adjusted. The default value is 0.664.
The Pixel Size Factor value accounts for changes in scale as the viewer zooms in and out on the map display. It controls the rate at which the z-factor changes. This parameter is only valid when the Scaling type is Adjusted. The default value is 0.024.
Shaded Relief options
You can import a layer or a package to set the parameters.
You can save your symbology as a raster function template.
Vector Field
Vector Field symbology uses a magnitude and direction component—or a U and V component, sometimes referred to as the zonal velocity and the meridional velocity—to display data. A common use is to display ocean or wind currents as arrows in which the direction indicates the flow, and the size of the arrow is related to the power of the current.
Primary symbology options
By default, the pane is set up to work with data that shows magnitude and direction. You can also use the Vector Field renderer to visualize a single raster layer with a vector symbol. Select the appropriate bands or variables for these inputs. There are two ways to calculate flow. Meteorological displays the vectors based on the direction from which the current is coming. Oceanographic is the opposite; it shows the direction the current is flowing.
There are several options for Symbol type, including a single arrow, which is a generic option applicable to many scenarios. There are also options for displaying wind as barbs or based on the Beaufort wind scale, and for displaying ocean currents.
The Symbol spacing value refers to the size of the area that each vector represents on the map.
The Symbol size value can range from 0 to 100. Decreasing this range from its full extent allows you to visualize a greater level of detail in the moderate values.
The More properties button adjusts the minimum and maximum values for the magnitudes, changes the units, and adjusts the angle reference system and direction.
Advanced symbology options
The following parameters are available on the More Properties tab:
- Magnitude—Set the minimum and maximum magnitude range.
- Unit—Set the measurement units for the magnitude.
- Angle reference system—Specify how the direction of the component was measured. Arithmetic indicates 0 degrees is due east and 90 degrees is due north. Geographic indicates 0 degrees is due north and 90 degrees is due east.
- Angle direction—Specify the direction of the mass flow. From (meteorological) indicates the mass is flowing along the angle and moving toward the origin of the reference system. To (oceanographic) indicates the mass is flowing along the angle and moving away from the origin of the reference system.
Vector Field renderer options
You can access the Vector Field renderer options using the Options button at the top of the Symbology pane.
You can import a layer or a package to set the parameters.
You can save your symbology as a raster function template.
Related topics
- Imagery appearance
- Raster histogram stretching
- Modify class breaks with a histogram
- Use advanced labeling for a continuous raster dataset
- Raster and imagery default options
Feedback on this topic?
Source: https://pro.arcgis.com/en/pro-app/latest/help/data/imagery/symbology-pane.htm
0 Response to "Python Return Continuous Strech of Numbers in a List"
Post a Comment