Here are the examples of the python api bokeh.transform.log_cmap taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.
2 Examples
3
View Source File : test_transform.py
License : MIT License
Project Creator : rthorst
License : MIT License
Project Creator : rthorst
def test_basic(self):
t = bt.log_cmap("foo", ["red", "green"], 0, 10, low_color="orange", high_color="blue", nan_color="pink")
assert isinstance(t, dict)
assert set(t) == {"field", "transform"}
assert t['field'] == "foo"
assert isinstance(t['transform'], LogColorMapper)
assert t['transform'].palette == ["red", "green"]
assert t['transform'].low == 0
assert t['transform'].high == 10
assert t['transform'].low_color == "orange"
assert t['transform'].high_color == "blue"
assert t['transform'].nan_color == "pink"
def test_defaults(self):
3
View Source File : test_transform.py
License : MIT License
Project Creator : rthorst
License : MIT License
Project Creator : rthorst
def test_defaults(self):
t = bt.log_cmap("foo", ["red", "green"], 0, 10)
assert isinstance(t, dict)
assert set(t) == {"field", "transform"}
assert t['field'] == "foo"
assert isinstance(t['transform'], LogColorMapper)
assert t['transform'].palette == ["red", "green"]
assert t['transform'].low == 0
assert t['transform'].high == 10
assert t['transform'].low_color is None
assert t['transform'].high_color is None
assert t['transform'].nan_color == "gray"
class Test_stack(object):