tracktable.render.map_decoration.colormaps module
Module contents
Several usable, mostly-accessible color maps for use when rendering points and trajectories
These colormaps are registered with matplotlib so that you can refer to them by name just as you can the standard ones.
Colormaps registered are available by name through
matplotlib.colormaps[cmap_name]. You can also use them with
render_trajectories() regardless of which back end you’re using.
Here are the names of all the color maps:
red_blue
orange_yellow_white
blue_turquoise_white
approach_departure
orange_white_blue
blue_white_orange
blue_white_orange_semitransparent
_ blue_white_orange_opaque - blue_white_orange_brighter - blue_white_orange_invisible_middle - all_white - all_grey50 - all_yellow - yellow_orange - orange_yellow - turquoise_blue - blue_turquoise
- tracktable.render.map_decoration.colormaps.all_grey50_colormap() matplotlib.colors.Colormap[source]
Return an all-50%-grey
All grey, all the time.
No arguments.
- Returns:
50% grey from beginning to end
- Return type:
mpl.colors.Colormap
- tracktable.render.map_decoration.colormaps.all_white_colormap() matplotlib.colors.Colormap[source]
Return an all-white color map
All white, all the time.
No arguments.
- Returns:
White from beginning to end
- Return type:
mpl.colors.Colormap
- tracktable.render.map_decoration.colormaps.all_yellow_colormap() matplotlib.colors.Colormap[source]
All yellow, all the time
No arguments.
- Returns:
Colormap that’s always yellow
- Return type:
mpl.colors.Colormap
- tracktable.render.map_decoration.colormaps.approach_departure_colormap() matplotlib.colors.Colormap[source]
Return a blue-white-orange colormap
This colormap is useful for highlighting flights on approach or departure. Use climb rate as the color variable and normalize so that a climb rate of 0 maps to 0.5. The blues at the bottom are negative climb rates that usually indicate approach and landing. The oranges at the top are climbs that indicate departures. The semitransparent whites in the middle are level flight.
No arguments.
- Returns:
Blue/white/orange colormap
- Return type:
mpl.colors.Colormap
- tracktable.render.map_decoration.colormaps.blue_turquoise_colormap() matplotlib.colors.Colormap[source]
Gradient from blue to turquoise
No arguments.
- Returns:
Colormap that’s blue at the start, turquoise at the end
- Return type:
mpl.colors.Colormap
- tracktable.render.map_decoration.colormaps.blue_turquoise_white_colormap() matplotlib.colors.Colormap[source]
Create a colormap that goes smoothly from blue to turquoise to white
No arguments.
- Returns:
New colormap for blue->turquoise->white
- Return type:
mpl.colors.Colormap
- tracktable.render.map_decoration.colormaps.blue_white_orange_brighter_colormap() matplotlib.colors.Colormap[source]
Create a blue-white-orange colormap, very bright
Colors are evenly spaced: blue at 0, white at 0.5, orange at 1. Colors are brighter (closer to white). Good for images being shown on dim or low-contrast screens.
No arguments.
- Returns:
Blue->white->orange
- Return type:
mpl.colors.Colormap
- tracktable.render.map_decoration.colormaps.blue_white_orange_colormap() matplotlib.colors.Colormap[source]
Create a blue-white-orange colormap
Colors are evenly spaced: blue at 0, white at 0.5, orange at 1. Semitransparent in the middle. This is the reverse of orange_white_blue.
No arguments.
- Returns:
Blue->white->orange
- Return type:
mpl.colors.Colormap
- tracktable.render.map_decoration.colormaps.blue_white_orange_invisible_middle_colormap() matplotlib.colors.Colormap[source]
Create a blue-white-orange colormap, middle is invisible
Colors are evenly spaced: blue at 0, white at 0.5, orange at 1. The middle of the colormap is completely invisible. Good for just showing the low and high ends of the color space.
No arguments.
- Returns:
Blue->white->orange
- Return type:
mpl.colors.Colormap
- tracktable.render.map_decoration.colormaps.blue_white_orange_opaque_colormap() matplotlib.colors.Colormap[source]
Create a blue-white-orange colormap, all opaque
Colors are evenly spaced: blue at 0, white at 0.5, orange at 1. All opaque. This gets confused when lots of lines pile up but is better for reading sparese traffic.
No arguments.
- Returns:
Blue->white->orange
- Return type:
mpl.colors.Colormap
- tracktable.render.map_decoration.colormaps.blue_white_orange_semitransparent_colormap() matplotlib.colors.Colormap[source]
Create a blue-white-orange colormap with alpha=0.5
Colors are evenly spaced: blue at 0, white at 0.5, orange at 1. All semitransparent. Alpha goes all the way down to 0.2 in the middle. This lets you maintain a more readable image when lots of lines pile up on top of one another.
No arguments.
- Returns:
Blue->white->orange
- Return type:
mpl.colors.Colormap
- tracktable.render.map_decoration.colormaps.dark_to_light_grey_colormap() matplotlib.colors.Colormap[source]
Gradient from dark to light grey
No arguments.
- Returns:
Colormap that’s dark grey at the start, light grey at the end
- Return type:
mpl.colors.Colormap
- tracktable.render.map_decoration.colormaps.light_to_dark_grey_colormap() matplotlib.colors.Colormap[source]
Gradient from light to dark grey
No arguments.
- Returns:
Colormap that’s light grey at the start, dark grey at the end
- Return type:
mpl.colors.Colormap
- tracktable.render.map_decoration.colormaps.make_simple_colormap(name: str, color_list: list[str | tuple[float, float, float] | tuple[float, float, float, float] | tuple[str, float]]) matplotlib.colors.Colormap[source]
Create a colormap by spacing colors evenly from 0 to 1
Take a list of 2 or more colors and space them evenly from 0 to 1. The result will be instantiated as a named Matplotlib color map and returned. You must still register the color map yourself.
- Parameters:
- Returns:
New colormap object.
- Return type:
mpl.colors.Colormap
- tracktable.render.map_decoration.colormaps.orange_white_blue_colormap() matplotlib.colors.Colormap[source]
Create an orange-white-blue colormap
Colors are evenly spaced: orange at 0, white at 0.5, blue at 1. Semitransparent in the middle.
No arguments.
- Returns:
Orange->white->blue
- Return type:
mpl.colors.Colormap
- tracktable.render.map_decoration.colormaps.orange_yellow_colormap() matplotlib.colors.Colormap[source]
Gradient from orange to yellow
No arguments.
- Returns:
Colormap that’s orange at the start, shading to yellow
- Return type:
mpl.colors.Colormap
- tracktable.render.map_decoration.colormaps.orange_yellow_white_colormap() matplotlib.colors.Colormap[source]
Create a colormap that goes smoothly from orange to yellow to white
No arguments.
- Returns:
New colormap for orange->yellow->white
- Return type:
mpl.colors.Colormap
- tracktable.render.map_decoration.colormaps.red_blue_colormap() matplotlib.colors.Colormap[source]
Create a colormap that goes smoothly from red to blue
No arguments.
- Returns:
New colormap for red->blue
- Return type:
mpl.colors.Colormap
- tracktable.render.map_decoration.colormaps.register_colormaps()[source]
Register all colormaps with Matplotlib.
This function is idempotent. It checks the COLORMAPS_REGISTERED flag before taking any action, then sets that flag when finished. It will execute when you import the module for the first time.
No arguments.
Returns None.
- tracktable.render.map_decoration.colormaps.turquoise_blue_colormap() matplotlib.colors.Colormap[source]
Gradient from turquoise to blue
No arguments.
- Returns:
Colormap that’s turquoise at the start, blue at the end
- Return type:
mpl.colors.Colormap
- tracktable.render.map_decoration.colormaps.yellow_orange_colormap() matplotlib.colors.Colormap[source]
Gradient from yellow to orange
No arguments.
- Returns:
Colormap that’s yellow at the start, shading to orange
- Return type:
mpl.colors.Colormap