| AHELP for CIAO 4.5 ChIPS v1 | remove_image_channel |
Context: images |
Synopsis
Add or delete a channel from the image.
Syntax
remove_image_channel([ChipsId,] channel) set_image_channel([ChipsId,] filename, channel) set_image_channel([ChipsId,] image_array, x-dim, y-dim, channel)
Description
- ChipsId - an optional ChipsId structure containing values to modify the currency state for the command.
- channel - the image channel to delete: chips_red, chips_green, chips_blue, or chips_alpha.
The remove_image_channel command deletes the specifed channel from the image. This command can only be used with true color images; an error is returned if the images is pseudocolor.
A different channel filter can be loaded for the image with the set_image_channel command.
Example 1
chips> add_image("soft.fits", "med.fits", "hard.fits")
chips> remove_image_channel(chips_red)Load three image files to create a truecolor image. Then remove the contribution of the red image, soft.fits, from the display.
Example 2
chips> image = read_file("input.fits")
chips> pixels = get_piximgvals(image)
chips> alpha = pixels * 0
chips> index = np.where(pixels > 0)
chips> alpha[index] = 1
chips> set_image_channel(alpha, chips_alpha)An alpha filter is created based on the pixel values in the image "input.fits". The set_image_channel command is used to set the alpha channel in the current image.
Bugs
See the bugs pages on the ChIPS website for an up-to-date listing of known bugs.
See Also
- contrib
- imextent
- images
- add_image, current_image, delete_image, display_image, get_image, hide_image, load_colormap, print_image, set_image, shuffle_image

![[ChIPS Logo]](../imgs/chips_logo_navbar.gif)