File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 155155
156156
157157###############################################################################
158- # Now we will use this example to illustrate 3 ways of
158+ # Now we will use this example to illustrate 2 ways of
159159# handling custom colormaps.
160160# First, the most direct and explicit:
161161
170170blue_red2 = LinearSegmentedColormap ('BlueRed2' , cdict2 )
171171plt .register_cmap (cmap = blue_red2 )
172172
173- ###############################################################################
174- # Third, for LinearSegmentedColormap only,
175- # leave everything to register_cmap:
176-
177- plt .register_cmap (name = 'BlueRed3' , data = cdict3 ) # optional lut kwarg
178- plt .register_cmap (name = 'BlueRedAlpha' , data = cdict4 )
173+ plt .register_cmap (cmap = LinearSegmentedColormap ('BlueRed3' , cdict3 ))
174+ plt .register_cmap (cmap = LinearSegmentedColormap ('BlueRedAlpha' , cdict4 ))
179175
180176###############################################################################
181177# Make the figure:
You can’t perform that action at this time.
0 commit comments