Skip to content

Commit

Permalink
Added span parameter for datashade operation
Browse files Browse the repository at this point in the history
  • Loading branch information
philippjfr committed Jun 1, 2017
1 parent d697f4c commit a4fcad1
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions holoviews/operation/datashader.py
Original file line number Diff line number Diff line change
Expand Up @@ -337,6 +337,11 @@ class shade(Operation):
and any valid transfer function that accepts data, mask, nbins
arguments.""")

span = param.NumericTuple(default=None, length=2, doc="""
Min and max data values to use for colormap interpolation, when
wishing to override autoranging.
""")

link_inputs = param.Boolean(default=True, doc="""
By default, the link_inputs parameter is set to True so that
when applying shade, backends that support linked streams
Expand Down Expand Up @@ -409,6 +414,8 @@ def _process(self, element, key=None):
shade_opts['cmap'] = map(self.rgb2hex, colors)
else:
shade_opts['cmap'] = self.p.cmap
if self.p.span:
shade_opts['span'] = self.p.span

with warnings.catch_warnings():
warnings.filterwarnings('ignore', r'invalid value encountered in true_divide')
Expand Down

0 comments on commit a4fcad1

Please sign in to comment.