Search is not available for this dataset
identifier
stringlengths 1
155
| parameters
stringlengths 2
6.09k
| docstring
stringlengths 11
63.4k
| docstring_summary
stringlengths 0
63.4k
| function
stringlengths 29
99.8k
| function_tokens
sequence | start_point
sequence | end_point
sequence | language
stringclasses 1
value | docstring_language
stringlengths 2
7
| docstring_language_predictions
stringlengths 18
23
| is_langid_reliable
stringclasses 2
values |
---|---|---|---|---|---|---|---|---|---|---|---|
ErrorX.array | (self) |
Sets the data corresponding the length of each error bar.
Values are plotted relative to the underlying data.
The 'array' property is an array that may be specified as a tuple,
list, numpy array, or pandas Series
Returns
-------
numpy.ndarray
|
Sets the data corresponding the length of each error bar.
Values are plotted relative to the underlying data.
The 'array' property is an array that may be specified as a tuple,
list, numpy array, or pandas Series | def array(self):
"""
Sets the data corresponding the length of each error bar.
Values are plotted relative to the underlying data.
The 'array' property is an array that may be specified as a tuple,
list, numpy array, or pandas Series
Returns
-------
numpy.ndarray
"""
return self["array"] | [
"def",
"array",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"array\"",
"]"
] | [
31,
4
] | [
43,
28
] | python | en | ['en', 'error', 'th'] | False |
ErrorX.arrayminus | (self) |
Sets the data corresponding the length of each error bar in the
bottom (left) direction for vertical (horizontal) bars Values
are plotted relative to the underlying data.
The 'arrayminus' property is an array that may be specified as a tuple,
list, numpy array, or pandas Series
Returns
-------
numpy.ndarray
|
Sets the data corresponding the length of each error bar in the
bottom (left) direction for vertical (horizontal) bars Values
are plotted relative to the underlying data.
The 'arrayminus' property is an array that may be specified as a tuple,
list, numpy array, or pandas Series | def arrayminus(self):
"""
Sets the data corresponding the length of each error bar in the
bottom (left) direction for vertical (horizontal) bars Values
are plotted relative to the underlying data.
The 'arrayminus' property is an array that may be specified as a tuple,
list, numpy array, or pandas Series
Returns
-------
numpy.ndarray
"""
return self["arrayminus"] | [
"def",
"arrayminus",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"arrayminus\"",
"]"
] | [
52,
4
] | [
65,
33
] | python | en | ['en', 'error', 'th'] | False |
ErrorX.arrayminussrc | (self) |
Sets the source reference on Chart Studio Cloud for arrayminus
.
The 'arrayminussrc' property must be specified as a string or
as a plotly.grid_objs.Column object
Returns
-------
str
|
Sets the source reference on Chart Studio Cloud for arrayminus
.
The 'arrayminussrc' property must be specified as a string or
as a plotly.grid_objs.Column object | def arrayminussrc(self):
"""
Sets the source reference on Chart Studio Cloud for arrayminus
.
The 'arrayminussrc' property must be specified as a string or
as a plotly.grid_objs.Column object
Returns
-------
str
"""
return self["arrayminussrc"] | [
"def",
"arrayminussrc",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"arrayminussrc\"",
"]"
] | [
74,
4
] | [
86,
36
] | python | en | ['en', 'error', 'th'] | False |
ErrorX.arraysrc | (self) |
Sets the source reference on Chart Studio Cloud for array .
The 'arraysrc' property must be specified as a string or
as a plotly.grid_objs.Column object
Returns
-------
str
|
Sets the source reference on Chart Studio Cloud for array .
The 'arraysrc' property must be specified as a string or
as a plotly.grid_objs.Column object | def arraysrc(self):
"""
Sets the source reference on Chart Studio Cloud for array .
The 'arraysrc' property must be specified as a string or
as a plotly.grid_objs.Column object
Returns
-------
str
"""
return self["arraysrc"] | [
"def",
"arraysrc",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"arraysrc\"",
"]"
] | [
95,
4
] | [
106,
31
] | python | en | ['en', 'error', 'th'] | False |
ErrorX.color | (self) |
Sets the stoke color of the error bars.
The 'color' property is a color and may be specified as:
- A hex string (e.g. '#ff0000')
- An rgb/rgba string (e.g. 'rgb(255,0,0)')
- An hsl/hsla string (e.g. 'hsl(0,100%,50%)')
- An hsv/hsva string (e.g. 'hsv(0,100%,100%)')
- A named CSS color:
aliceblue, antiquewhite, aqua, aquamarine, azure,
beige, bisque, black, blanchedalmond, blue,
blueviolet, brown, burlywood, cadetblue,
chartreuse, chocolate, coral, cornflowerblue,
cornsilk, crimson, cyan, darkblue, darkcyan,
darkgoldenrod, darkgray, darkgrey, darkgreen,
darkkhaki, darkmagenta, darkolivegreen, darkorange,
darkorchid, darkred, darksalmon, darkseagreen,
darkslateblue, darkslategray, darkslategrey,
darkturquoise, darkviolet, deeppink, deepskyblue,
dimgray, dimgrey, dodgerblue, firebrick,
floralwhite, forestgreen, fuchsia, gainsboro,
ghostwhite, gold, goldenrod, gray, grey, green,
greenyellow, honeydew, hotpink, indianred, indigo,
ivory, khaki, lavender, lavenderblush, lawngreen,
lemonchiffon, lightblue, lightcoral, lightcyan,
lightgoldenrodyellow, lightgray, lightgrey,
lightgreen, lightpink, lightsalmon, lightseagreen,
lightskyblue, lightslategray, lightslategrey,
lightsteelblue, lightyellow, lime, limegreen,
linen, magenta, maroon, mediumaquamarine,
mediumblue, mediumorchid, mediumpurple,
mediumseagreen, mediumslateblue, mediumspringgreen,
mediumturquoise, mediumvioletred, midnightblue,
mintcream, mistyrose, moccasin, navajowhite, navy,
oldlace, olive, olivedrab, orange, orangered,
orchid, palegoldenrod, palegreen, paleturquoise,
palevioletred, papayawhip, peachpuff, peru, pink,
plum, powderblue, purple, red, rosybrown,
royalblue, rebeccapurple, saddlebrown, salmon,
sandybrown, seagreen, seashell, sienna, silver,
skyblue, slateblue, slategray, slategrey, snow,
springgreen, steelblue, tan, teal, thistle, tomato,
turquoise, violet, wheat, white, whitesmoke,
yellow, yellowgreen
Returns
-------
str
|
Sets the stoke color of the error bars.
The 'color' property is a color and may be specified as:
- A hex string (e.g. '#ff0000')
- An rgb/rgba string (e.g. 'rgb(255,0,0)')
- An hsl/hsla string (e.g. 'hsl(0,100%,50%)')
- An hsv/hsva string (e.g. 'hsv(0,100%,100%)')
- A named CSS color:
aliceblue, antiquewhite, aqua, aquamarine, azure,
beige, bisque, black, blanchedalmond, blue,
blueviolet, brown, burlywood, cadetblue,
chartreuse, chocolate, coral, cornflowerblue,
cornsilk, crimson, cyan, darkblue, darkcyan,
darkgoldenrod, darkgray, darkgrey, darkgreen,
darkkhaki, darkmagenta, darkolivegreen, darkorange,
darkorchid, darkred, darksalmon, darkseagreen,
darkslateblue, darkslategray, darkslategrey,
darkturquoise, darkviolet, deeppink, deepskyblue,
dimgray, dimgrey, dodgerblue, firebrick,
floralwhite, forestgreen, fuchsia, gainsboro,
ghostwhite, gold, goldenrod, gray, grey, green,
greenyellow, honeydew, hotpink, indianred, indigo,
ivory, khaki, lavender, lavenderblush, lawngreen,
lemonchiffon, lightblue, lightcoral, lightcyan,
lightgoldenrodyellow, lightgray, lightgrey,
lightgreen, lightpink, lightsalmon, lightseagreen,
lightskyblue, lightslategray, lightslategrey,
lightsteelblue, lightyellow, lime, limegreen,
linen, magenta, maroon, mediumaquamarine,
mediumblue, mediumorchid, mediumpurple,
mediumseagreen, mediumslateblue, mediumspringgreen,
mediumturquoise, mediumvioletred, midnightblue,
mintcream, mistyrose, moccasin, navajowhite, navy,
oldlace, olive, olivedrab, orange, orangered,
orchid, palegoldenrod, palegreen, paleturquoise,
palevioletred, papayawhip, peachpuff, peru, pink,
plum, powderblue, purple, red, rosybrown,
royalblue, rebeccapurple, saddlebrown, salmon,
sandybrown, seagreen, seashell, sienna, silver,
skyblue, slateblue, slategray, slategrey, snow,
springgreen, steelblue, tan, teal, thistle, tomato,
turquoise, violet, wheat, white, whitesmoke,
yellow, yellowgreen | def color(self):
"""
Sets the stoke color of the error bars.
The 'color' property is a color and may be specified as:
- A hex string (e.g. '#ff0000')
- An rgb/rgba string (e.g. 'rgb(255,0,0)')
- An hsl/hsla string (e.g. 'hsl(0,100%,50%)')
- An hsv/hsva string (e.g. 'hsv(0,100%,100%)')
- A named CSS color:
aliceblue, antiquewhite, aqua, aquamarine, azure,
beige, bisque, black, blanchedalmond, blue,
blueviolet, brown, burlywood, cadetblue,
chartreuse, chocolate, coral, cornflowerblue,
cornsilk, crimson, cyan, darkblue, darkcyan,
darkgoldenrod, darkgray, darkgrey, darkgreen,
darkkhaki, darkmagenta, darkolivegreen, darkorange,
darkorchid, darkred, darksalmon, darkseagreen,
darkslateblue, darkslategray, darkslategrey,
darkturquoise, darkviolet, deeppink, deepskyblue,
dimgray, dimgrey, dodgerblue, firebrick,
floralwhite, forestgreen, fuchsia, gainsboro,
ghostwhite, gold, goldenrod, gray, grey, green,
greenyellow, honeydew, hotpink, indianred, indigo,
ivory, khaki, lavender, lavenderblush, lawngreen,
lemonchiffon, lightblue, lightcoral, lightcyan,
lightgoldenrodyellow, lightgray, lightgrey,
lightgreen, lightpink, lightsalmon, lightseagreen,
lightskyblue, lightslategray, lightslategrey,
lightsteelblue, lightyellow, lime, limegreen,
linen, magenta, maroon, mediumaquamarine,
mediumblue, mediumorchid, mediumpurple,
mediumseagreen, mediumslateblue, mediumspringgreen,
mediumturquoise, mediumvioletred, midnightblue,
mintcream, mistyrose, moccasin, navajowhite, navy,
oldlace, olive, olivedrab, orange, orangered,
orchid, palegoldenrod, palegreen, paleturquoise,
palevioletred, papayawhip, peachpuff, peru, pink,
plum, powderblue, purple, red, rosybrown,
royalblue, rebeccapurple, saddlebrown, salmon,
sandybrown, seagreen, seashell, sienna, silver,
skyblue, slateblue, slategray, slategrey, snow,
springgreen, steelblue, tan, teal, thistle, tomato,
turquoise, violet, wheat, white, whitesmoke,
yellow, yellowgreen
Returns
-------
str
"""
return self["color"] | [
"def",
"color",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"color\"",
"]"
] | [
115,
4
] | [
165,
28
] | python | en | ['en', 'error', 'th'] | False |
ErrorX.copy_ystyle | (self) |
The 'copy_ystyle' property must be specified as a bool
(either True, or False)
Returns
-------
bool
|
The 'copy_ystyle' property must be specified as a bool
(either True, or False) | def copy_ystyle(self):
"""
The 'copy_ystyle' property must be specified as a bool
(either True, or False)
Returns
-------
bool
"""
return self["copy_ystyle"] | [
"def",
"copy_ystyle",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"copy_ystyle\"",
"]"
] | [
174,
4
] | [
183,
34
] | python | en | ['en', 'error', 'th'] | False |
ErrorX.symmetric | (self) |
Determines whether or not the error bars have the same length
in both direction (top/bottom for vertical bars, left/right for
horizontal bars.
The 'symmetric' property must be specified as a bool
(either True, or False)
Returns
-------
bool
|
Determines whether or not the error bars have the same length
in both direction (top/bottom for vertical bars, left/right for
horizontal bars.
The 'symmetric' property must be specified as a bool
(either True, or False) | def symmetric(self):
"""
Determines whether or not the error bars have the same length
in both direction (top/bottom for vertical bars, left/right for
horizontal bars.
The 'symmetric' property must be specified as a bool
(either True, or False)
Returns
-------
bool
"""
return self["symmetric"] | [
"def",
"symmetric",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"symmetric\"",
"]"
] | [
192,
4
] | [
205,
32
] | python | en | ['en', 'error', 'th'] | False |
ErrorX.thickness | (self) |
Sets the thickness (in px) of the error bars.
The 'thickness' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
|
Sets the thickness (in px) of the error bars.
The 'thickness' property is a number and may be specified as:
- An int or float in the interval [0, inf] | def thickness(self):
"""
Sets the thickness (in px) of the error bars.
The 'thickness' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
"""
return self["thickness"] | [
"def",
"thickness",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"thickness\"",
"]"
] | [
214,
4
] | [
225,
32
] | python | en | ['en', 'error', 'th'] | False |
ErrorX.traceref | (self) |
The 'traceref' property is a integer and may be specified as:
- An int (or float that will be cast to an int)
in the interval [0, 9223372036854775807]
Returns
-------
int
|
The 'traceref' property is a integer and may be specified as:
- An int (or float that will be cast to an int)
in the interval [0, 9223372036854775807] | def traceref(self):
"""
The 'traceref' property is a integer and may be specified as:
- An int (or float that will be cast to an int)
in the interval [0, 9223372036854775807]
Returns
-------
int
"""
return self["traceref"] | [
"def",
"traceref",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"traceref\"",
"]"
] | [
234,
4
] | [
244,
31
] | python | en | ['en', 'error', 'th'] | False |
ErrorX.tracerefminus | (self) |
The 'tracerefminus' property is a integer and may be specified as:
- An int (or float that will be cast to an int)
in the interval [0, 9223372036854775807]
Returns
-------
int
|
The 'tracerefminus' property is a integer and may be specified as:
- An int (or float that will be cast to an int)
in the interval [0, 9223372036854775807] | def tracerefminus(self):
"""
The 'tracerefminus' property is a integer and may be specified as:
- An int (or float that will be cast to an int)
in the interval [0, 9223372036854775807]
Returns
-------
int
"""
return self["tracerefminus"] | [
"def",
"tracerefminus",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"tracerefminus\"",
"]"
] | [
253,
4
] | [
263,
36
] | python | en | ['en', 'error', 'th'] | False |
ErrorX.type | (self) |
Determines the rule used to generate the error bars. If
*constant`, the bar lengths are of a constant value. Set this
constant in `value`. If "percent", the bar lengths correspond
to a percentage of underlying data. Set this percentage in
`value`. If "sqrt", the bar lengths correspond to the sqaure of
the underlying data. If "data", the bar lengths are set with
data set `array`.
The 'type' property is an enumeration that may be specified as:
- One of the following enumeration values:
['percent', 'constant', 'sqrt', 'data']
Returns
-------
Any
|
Determines the rule used to generate the error bars. If
*constant`, the bar lengths are of a constant value. Set this
constant in `value`. If "percent", the bar lengths correspond
to a percentage of underlying data. Set this percentage in
`value`. If "sqrt", the bar lengths correspond to the sqaure of
the underlying data. If "data", the bar lengths are set with
data set `array`.
The 'type' property is an enumeration that may be specified as:
- One of the following enumeration values:
['percent', 'constant', 'sqrt', 'data'] | def type(self):
"""
Determines the rule used to generate the error bars. If
*constant`, the bar lengths are of a constant value. Set this
constant in `value`. If "percent", the bar lengths correspond
to a percentage of underlying data. Set this percentage in
`value`. If "sqrt", the bar lengths correspond to the sqaure of
the underlying data. If "data", the bar lengths are set with
data set `array`.
The 'type' property is an enumeration that may be specified as:
- One of the following enumeration values:
['percent', 'constant', 'sqrt', 'data']
Returns
-------
Any
"""
return self["type"] | [
"def",
"type",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"type\"",
"]"
] | [
272,
4
] | [
290,
27
] | python | en | ['en', 'error', 'th'] | False |
ErrorX.value | (self) |
Sets the value of either the percentage (if `type` is set to
"percent") or the constant (if `type` is set to "constant")
corresponding to the lengths of the error bars.
The 'value' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
|
Sets the value of either the percentage (if `type` is set to
"percent") or the constant (if `type` is set to "constant")
corresponding to the lengths of the error bars.
The 'value' property is a number and may be specified as:
- An int or float in the interval [0, inf] | def value(self):
"""
Sets the value of either the percentage (if `type` is set to
"percent") or the constant (if `type` is set to "constant")
corresponding to the lengths of the error bars.
The 'value' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
"""
return self["value"] | [
"def",
"value",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"value\"",
"]"
] | [
299,
4
] | [
312,
28
] | python | en | ['en', 'error', 'th'] | False |
ErrorX.valueminus | (self) |
Sets the value of either the percentage (if `type` is set to
"percent") or the constant (if `type` is set to "constant")
corresponding to the lengths of the error bars in the bottom
(left) direction for vertical (horizontal) bars
The 'valueminus' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
|
Sets the value of either the percentage (if `type` is set to
"percent") or the constant (if `type` is set to "constant")
corresponding to the lengths of the error bars in the bottom
(left) direction for vertical (horizontal) bars
The 'valueminus' property is a number and may be specified as:
- An int or float in the interval [0, inf] | def valueminus(self):
"""
Sets the value of either the percentage (if `type` is set to
"percent") or the constant (if `type` is set to "constant")
corresponding to the lengths of the error bars in the bottom
(left) direction for vertical (horizontal) bars
The 'valueminus' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
"""
return self["valueminus"] | [
"def",
"valueminus",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"valueminus\"",
"]"
] | [
321,
4
] | [
335,
33
] | python | en | ['en', 'error', 'th'] | False |
ErrorX.visible | (self) |
Determines whether or not this set of error bars is visible.
The 'visible' property must be specified as a bool
(either True, or False)
Returns
-------
bool
|
Determines whether or not this set of error bars is visible.
The 'visible' property must be specified as a bool
(either True, or False) | def visible(self):
"""
Determines whether or not this set of error bars is visible.
The 'visible' property must be specified as a bool
(either True, or False)
Returns
-------
bool
"""
return self["visible"] | [
"def",
"visible",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"visible\"",
"]"
] | [
344,
4
] | [
355,
30
] | python | en | ['en', 'error', 'th'] | False |
ErrorX.width | (self) |
Sets the width (in px) of the cross-bar at both ends of the
error bars.
The 'width' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
|
Sets the width (in px) of the cross-bar at both ends of the
error bars.
The 'width' property is a number and may be specified as:
- An int or float in the interval [0, inf] | def width(self):
"""
Sets the width (in px) of the cross-bar at both ends of the
error bars.
The 'width' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
"""
return self["width"] | [
"def",
"width",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"width\"",
"]"
] | [
364,
4
] | [
376,
28
] | python | en | ['en', 'error', 'th'] | False |
ErrorX.__init__ | (
self,
arg=None,
array=None,
arrayminus=None,
arrayminussrc=None,
arraysrc=None,
color=None,
copy_ystyle=None,
symmetric=None,
thickness=None,
traceref=None,
tracerefminus=None,
type=None,
value=None,
valueminus=None,
visible=None,
width=None,
**kwargs
) |
Construct a new ErrorX object
Parameters
----------
arg
dict of properties compatible with this constructor or
an instance of
:class:`plotly.graph_objs.histogram.ErrorX`
array
Sets the data corresponding the length of each error
bar. Values are plotted relative to the underlying
data.
arrayminus
Sets the data corresponding the length of each error
bar in the bottom (left) direction for vertical
(horizontal) bars Values are plotted relative to the
underlying data.
arrayminussrc
Sets the source reference on Chart Studio Cloud for
arrayminus .
arraysrc
Sets the source reference on Chart Studio Cloud for
array .
color
Sets the stoke color of the error bars.
copy_ystyle
symmetric
Determines whether or not the error bars have the same
length in both direction (top/bottom for vertical bars,
left/right for horizontal bars.
thickness
Sets the thickness (in px) of the error bars.
traceref
tracerefminus
type
Determines the rule used to generate the error bars. If
*constant`, the bar lengths are of a constant value.
Set this constant in `value`. If "percent", the bar
lengths correspond to a percentage of underlying data.
Set this percentage in `value`. If "sqrt", the bar
lengths correspond to the sqaure of the underlying
data. If "data", the bar lengths are set with data set
`array`.
value
Sets the value of either the percentage (if `type` is
set to "percent") or the constant (if `type` is set to
"constant") corresponding to the lengths of the error
bars.
valueminus
Sets the value of either the percentage (if `type` is
set to "percent") or the constant (if `type` is set to
"constant") corresponding to the lengths of the error
bars in the bottom (left) direction for vertical
(horizontal) bars
visible
Determines whether or not this set of error bars is
visible.
width
Sets the width (in px) of the cross-bar at both ends of
the error bars.
Returns
-------
ErrorX
|
Construct a new ErrorX object
Parameters
----------
arg
dict of properties compatible with this constructor or
an instance of
:class:`plotly.graph_objs.histogram.ErrorX`
array
Sets the data corresponding the length of each error
bar. Values are plotted relative to the underlying
data.
arrayminus
Sets the data corresponding the length of each error
bar in the bottom (left) direction for vertical
(horizontal) bars Values are plotted relative to the
underlying data.
arrayminussrc
Sets the source reference on Chart Studio Cloud for
arrayminus .
arraysrc
Sets the source reference on Chart Studio Cloud for
array .
color
Sets the stoke color of the error bars.
copy_ystyle | def __init__(
self,
arg=None,
array=None,
arrayminus=None,
arrayminussrc=None,
arraysrc=None,
color=None,
copy_ystyle=None,
symmetric=None,
thickness=None,
traceref=None,
tracerefminus=None,
type=None,
value=None,
valueminus=None,
visible=None,
width=None,
**kwargs
):
"""
Construct a new ErrorX object
Parameters
----------
arg
dict of properties compatible with this constructor or
an instance of
:class:`plotly.graph_objs.histogram.ErrorX`
array
Sets the data corresponding the length of each error
bar. Values are plotted relative to the underlying
data.
arrayminus
Sets the data corresponding the length of each error
bar in the bottom (left) direction for vertical
(horizontal) bars Values are plotted relative to the
underlying data.
arrayminussrc
Sets the source reference on Chart Studio Cloud for
arrayminus .
arraysrc
Sets the source reference on Chart Studio Cloud for
array .
color
Sets the stoke color of the error bars.
copy_ystyle
symmetric
Determines whether or not the error bars have the same
length in both direction (top/bottom for vertical bars,
left/right for horizontal bars.
thickness
Sets the thickness (in px) of the error bars.
traceref
tracerefminus
type
Determines the rule used to generate the error bars. If
*constant`, the bar lengths are of a constant value.
Set this constant in `value`. If "percent", the bar
lengths correspond to a percentage of underlying data.
Set this percentage in `value`. If "sqrt", the bar
lengths correspond to the sqaure of the underlying
data. If "data", the bar lengths are set with data set
`array`.
value
Sets the value of either the percentage (if `type` is
set to "percent") or the constant (if `type` is set to
"constant") corresponding to the lengths of the error
bars.
valueminus
Sets the value of either the percentage (if `type` is
set to "percent") or the constant (if `type` is set to
"constant") corresponding to the lengths of the error
bars in the bottom (left) direction for vertical
(horizontal) bars
visible
Determines whether or not this set of error bars is
visible.
width
Sets the width (in px) of the cross-bar at both ends of
the error bars.
Returns
-------
ErrorX
"""
super(ErrorX, self).__init__("error_x")
if "_parent" in kwargs:
self._parent = kwargs["_parent"]
return
# Validate arg
# ------------
if arg is None:
arg = {}
elif isinstance(arg, self.__class__):
arg = arg.to_plotly_json()
elif isinstance(arg, dict):
arg = _copy.copy(arg)
else:
raise ValueError(
"""\
The first argument to the plotly.graph_objs.histogram.ErrorX
constructor must be a dict or
an instance of :class:`plotly.graph_objs.histogram.ErrorX`"""
)
# Handle skip_invalid
# -------------------
self._skip_invalid = kwargs.pop("skip_invalid", False)
self._validate = kwargs.pop("_validate", True)
# Populate data dict with properties
# ----------------------------------
_v = arg.pop("array", None)
_v = array if array is not None else _v
if _v is not None:
self["array"] = _v
_v = arg.pop("arrayminus", None)
_v = arrayminus if arrayminus is not None else _v
if _v is not None:
self["arrayminus"] = _v
_v = arg.pop("arrayminussrc", None)
_v = arrayminussrc if arrayminussrc is not None else _v
if _v is not None:
self["arrayminussrc"] = _v
_v = arg.pop("arraysrc", None)
_v = arraysrc if arraysrc is not None else _v
if _v is not None:
self["arraysrc"] = _v
_v = arg.pop("color", None)
_v = color if color is not None else _v
if _v is not None:
self["color"] = _v
_v = arg.pop("copy_ystyle", None)
_v = copy_ystyle if copy_ystyle is not None else _v
if _v is not None:
self["copy_ystyle"] = _v
_v = arg.pop("symmetric", None)
_v = symmetric if symmetric is not None else _v
if _v is not None:
self["symmetric"] = _v
_v = arg.pop("thickness", None)
_v = thickness if thickness is not None else _v
if _v is not None:
self["thickness"] = _v
_v = arg.pop("traceref", None)
_v = traceref if traceref is not None else _v
if _v is not None:
self["traceref"] = _v
_v = arg.pop("tracerefminus", None)
_v = tracerefminus if tracerefminus is not None else _v
if _v is not None:
self["tracerefminus"] = _v
_v = arg.pop("type", None)
_v = type if type is not None else _v
if _v is not None:
self["type"] = _v
_v = arg.pop("value", None)
_v = value if value is not None else _v
if _v is not None:
self["value"] = _v
_v = arg.pop("valueminus", None)
_v = valueminus if valueminus is not None else _v
if _v is not None:
self["valueminus"] = _v
_v = arg.pop("visible", None)
_v = visible if visible is not None else _v
if _v is not None:
self["visible"] = _v
_v = arg.pop("width", None)
_v = width if width is not None else _v
if _v is not None:
self["width"] = _v
# Process unknown kwargs
# ----------------------
self._process_kwargs(**dict(arg, **kwargs))
# Reset skip_invalid
# ------------------
self._skip_invalid = False | [
"def",
"__init__",
"(",
"self",
",",
"arg",
"=",
"None",
",",
"array",
"=",
"None",
",",
"arrayminus",
"=",
"None",
",",
"arrayminussrc",
"=",
"None",
",",
"arraysrc",
"=",
"None",
",",
"color",
"=",
"None",
",",
"copy_ystyle",
"=",
"None",
",",
"symmetric",
"=",
"None",
",",
"thickness",
"=",
"None",
",",
"traceref",
"=",
"None",
",",
"tracerefminus",
"=",
"None",
",",
"type",
"=",
"None",
",",
"value",
"=",
"None",
",",
"valueminus",
"=",
"None",
",",
"visible",
"=",
"None",
",",
"width",
"=",
"None",
",",
"*",
"*",
"kwargs",
")",
":",
"super",
"(",
"ErrorX",
",",
"self",
")",
".",
"__init__",
"(",
"\"error_x\"",
")",
"if",
"\"_parent\"",
"in",
"kwargs",
":",
"self",
".",
"_parent",
"=",
"kwargs",
"[",
"\"_parent\"",
"]",
"return",
"# Validate arg",
"# ------------",
"if",
"arg",
"is",
"None",
":",
"arg",
"=",
"{",
"}",
"elif",
"isinstance",
"(",
"arg",
",",
"self",
".",
"__class__",
")",
":",
"arg",
"=",
"arg",
".",
"to_plotly_json",
"(",
")",
"elif",
"isinstance",
"(",
"arg",
",",
"dict",
")",
":",
"arg",
"=",
"_copy",
".",
"copy",
"(",
"arg",
")",
"else",
":",
"raise",
"ValueError",
"(",
"\"\"\"\\\nThe first argument to the plotly.graph_objs.histogram.ErrorX \nconstructor must be a dict or \nan instance of :class:`plotly.graph_objs.histogram.ErrorX`\"\"\"",
")",
"# Handle skip_invalid",
"# -------------------",
"self",
".",
"_skip_invalid",
"=",
"kwargs",
".",
"pop",
"(",
"\"skip_invalid\"",
",",
"False",
")",
"self",
".",
"_validate",
"=",
"kwargs",
".",
"pop",
"(",
"\"_validate\"",
",",
"True",
")",
"# Populate data dict with properties",
"# ----------------------------------",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"array\"",
",",
"None",
")",
"_v",
"=",
"array",
"if",
"array",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"array\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"arrayminus\"",
",",
"None",
")",
"_v",
"=",
"arrayminus",
"if",
"arrayminus",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"arrayminus\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"arrayminussrc\"",
",",
"None",
")",
"_v",
"=",
"arrayminussrc",
"if",
"arrayminussrc",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"arrayminussrc\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"arraysrc\"",
",",
"None",
")",
"_v",
"=",
"arraysrc",
"if",
"arraysrc",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"arraysrc\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"color\"",
",",
"None",
")",
"_v",
"=",
"color",
"if",
"color",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"color\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"copy_ystyle\"",
",",
"None",
")",
"_v",
"=",
"copy_ystyle",
"if",
"copy_ystyle",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"copy_ystyle\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"symmetric\"",
",",
"None",
")",
"_v",
"=",
"symmetric",
"if",
"symmetric",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"symmetric\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"thickness\"",
",",
"None",
")",
"_v",
"=",
"thickness",
"if",
"thickness",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"thickness\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"traceref\"",
",",
"None",
")",
"_v",
"=",
"traceref",
"if",
"traceref",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"traceref\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"tracerefminus\"",
",",
"None",
")",
"_v",
"=",
"tracerefminus",
"if",
"tracerefminus",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"tracerefminus\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"type\"",
",",
"None",
")",
"_v",
"=",
"type",
"if",
"type",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"type\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"value\"",
",",
"None",
")",
"_v",
"=",
"value",
"if",
"value",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"value\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"valueminus\"",
",",
"None",
")",
"_v",
"=",
"valueminus",
"if",
"valueminus",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"valueminus\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"visible\"",
",",
"None",
")",
"_v",
"=",
"visible",
"if",
"visible",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"visible\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"width\"",
",",
"None",
")",
"_v",
"=",
"width",
"if",
"width",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"width\"",
"]",
"=",
"_v",
"# Process unknown kwargs",
"# ----------------------",
"self",
".",
"_process_kwargs",
"(",
"*",
"*",
"dict",
"(",
"arg",
",",
"*",
"*",
"kwargs",
")",
")",
"# Reset skip_invalid",
"# ------------------",
"self",
".",
"_skip_invalid",
"=",
"False"
] | [
444,
4
] | [
629,
34
] | python | en | ['en', 'error', 'th'] | False |
Unselected.marker | (self) |
The 'marker' property is an instance of Marker
that may be specified as:
- An instance of :class:`plotly.graph_objs.scatterternary.unselected.Marker`
- A dict of string/value properties that will be passed
to the Marker constructor
Supported dict properties:
color
Sets the marker color of unselected points,
applied only when a selection exists.
opacity
Sets the marker opacity of unselected points,
applied only when a selection exists.
size
Sets the marker size of unselected points,
applied only when a selection exists.
Returns
-------
plotly.graph_objs.scatterternary.unselected.Marker
|
The 'marker' property is an instance of Marker
that may be specified as:
- An instance of :class:`plotly.graph_objs.scatterternary.unselected.Marker`
- A dict of string/value properties that will be passed
to the Marker constructor
Supported dict properties:
color
Sets the marker color of unselected points,
applied only when a selection exists.
opacity
Sets the marker opacity of unselected points,
applied only when a selection exists.
size
Sets the marker size of unselected points,
applied only when a selection exists. | def marker(self):
"""
The 'marker' property is an instance of Marker
that may be specified as:
- An instance of :class:`plotly.graph_objs.scatterternary.unselected.Marker`
- A dict of string/value properties that will be passed
to the Marker constructor
Supported dict properties:
color
Sets the marker color of unselected points,
applied only when a selection exists.
opacity
Sets the marker opacity of unselected points,
applied only when a selection exists.
size
Sets the marker size of unselected points,
applied only when a selection exists.
Returns
-------
plotly.graph_objs.scatterternary.unselected.Marker
"""
return self["marker"] | [
"def",
"marker",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"marker\"",
"]"
] | [
15,
4
] | [
39,
29
] | python | en | ['en', 'error', 'th'] | False |
Unselected.textfont | (self) |
The 'textfont' property is an instance of Textfont
that may be specified as:
- An instance of :class:`plotly.graph_objs.scatterternary.unselected.Textfont`
- A dict of string/value properties that will be passed
to the Textfont constructor
Supported dict properties:
color
Sets the text font color of unselected points,
applied only when a selection exists.
Returns
-------
plotly.graph_objs.scatterternary.unselected.Textfont
|
The 'textfont' property is an instance of Textfont
that may be specified as:
- An instance of :class:`plotly.graph_objs.scatterternary.unselected.Textfont`
- A dict of string/value properties that will be passed
to the Textfont constructor
Supported dict properties:
color
Sets the text font color of unselected points,
applied only when a selection exists. | def textfont(self):
"""
The 'textfont' property is an instance of Textfont
that may be specified as:
- An instance of :class:`plotly.graph_objs.scatterternary.unselected.Textfont`
- A dict of string/value properties that will be passed
to the Textfont constructor
Supported dict properties:
color
Sets the text font color of unselected points,
applied only when a selection exists.
Returns
-------
plotly.graph_objs.scatterternary.unselected.Textfont
"""
return self["textfont"] | [
"def",
"textfont",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"textfont\"",
"]"
] | [
48,
4
] | [
66,
31
] | python | en | ['en', 'error', 'th'] | False |
Unselected.__init__ | (self, arg=None, marker=None, textfont=None, **kwargs) |
Construct a new Unselected object
Parameters
----------
arg
dict of properties compatible with this constructor or
an instance of
:class:`plotly.graph_objs.scatterternary.Unselected`
marker
:class:`plotly.graph_objects.scatterternary.unselected.
Marker` instance or dict with compatible properties
textfont
:class:`plotly.graph_objects.scatterternary.unselected.
Textfont` instance or dict with compatible properties
Returns
-------
Unselected
|
Construct a new Unselected object
Parameters
----------
arg
dict of properties compatible with this constructor or
an instance of
:class:`plotly.graph_objs.scatterternary.Unselected`
marker
:class:`plotly.graph_objects.scatterternary.unselected.
Marker` instance or dict with compatible properties
textfont
:class:`plotly.graph_objects.scatterternary.unselected.
Textfont` instance or dict with compatible properties | def __init__(self, arg=None, marker=None, textfont=None, **kwargs):
"""
Construct a new Unselected object
Parameters
----------
arg
dict of properties compatible with this constructor or
an instance of
:class:`plotly.graph_objs.scatterternary.Unselected`
marker
:class:`plotly.graph_objects.scatterternary.unselected.
Marker` instance or dict with compatible properties
textfont
:class:`plotly.graph_objects.scatterternary.unselected.
Textfont` instance or dict with compatible properties
Returns
-------
Unselected
"""
super(Unselected, self).__init__("unselected")
if "_parent" in kwargs:
self._parent = kwargs["_parent"]
return
# Validate arg
# ------------
if arg is None:
arg = {}
elif isinstance(arg, self.__class__):
arg = arg.to_plotly_json()
elif isinstance(arg, dict):
arg = _copy.copy(arg)
else:
raise ValueError(
"""\
The first argument to the plotly.graph_objs.scatterternary.Unselected
constructor must be a dict or
an instance of :class:`plotly.graph_objs.scatterternary.Unselected`"""
)
# Handle skip_invalid
# -------------------
self._skip_invalid = kwargs.pop("skip_invalid", False)
self._validate = kwargs.pop("_validate", True)
# Populate data dict with properties
# ----------------------------------
_v = arg.pop("marker", None)
_v = marker if marker is not None else _v
if _v is not None:
self["marker"] = _v
_v = arg.pop("textfont", None)
_v = textfont if textfont is not None else _v
if _v is not None:
self["textfont"] = _v
# Process unknown kwargs
# ----------------------
self._process_kwargs(**dict(arg, **kwargs))
# Reset skip_invalid
# ------------------
self._skip_invalid = False | [
"def",
"__init__",
"(",
"self",
",",
"arg",
"=",
"None",
",",
"marker",
"=",
"None",
",",
"textfont",
"=",
"None",
",",
"*",
"*",
"kwargs",
")",
":",
"super",
"(",
"Unselected",
",",
"self",
")",
".",
"__init__",
"(",
"\"unselected\"",
")",
"if",
"\"_parent\"",
"in",
"kwargs",
":",
"self",
".",
"_parent",
"=",
"kwargs",
"[",
"\"_parent\"",
"]",
"return",
"# Validate arg",
"# ------------",
"if",
"arg",
"is",
"None",
":",
"arg",
"=",
"{",
"}",
"elif",
"isinstance",
"(",
"arg",
",",
"self",
".",
"__class__",
")",
":",
"arg",
"=",
"arg",
".",
"to_plotly_json",
"(",
")",
"elif",
"isinstance",
"(",
"arg",
",",
"dict",
")",
":",
"arg",
"=",
"_copy",
".",
"copy",
"(",
"arg",
")",
"else",
":",
"raise",
"ValueError",
"(",
"\"\"\"\\\nThe first argument to the plotly.graph_objs.scatterternary.Unselected \nconstructor must be a dict or \nan instance of :class:`plotly.graph_objs.scatterternary.Unselected`\"\"\"",
")",
"# Handle skip_invalid",
"# -------------------",
"self",
".",
"_skip_invalid",
"=",
"kwargs",
".",
"pop",
"(",
"\"skip_invalid\"",
",",
"False",
")",
"self",
".",
"_validate",
"=",
"kwargs",
".",
"pop",
"(",
"\"_validate\"",
",",
"True",
")",
"# Populate data dict with properties",
"# ----------------------------------",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"marker\"",
",",
"None",
")",
"_v",
"=",
"marker",
"if",
"marker",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"marker\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"textfont\"",
",",
"None",
")",
"_v",
"=",
"textfont",
"if",
"textfont",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"textfont\"",
"]",
"=",
"_v",
"# Process unknown kwargs",
"# ----------------------",
"self",
".",
"_process_kwargs",
"(",
"*",
"*",
"dict",
"(",
"arg",
",",
"*",
"*",
"kwargs",
")",
")",
"# Reset skip_invalid",
"# ------------------",
"self",
".",
"_skip_invalid",
"=",
"False"
] | [
85,
4
] | [
150,
34
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.bgcolor | (self) |
Sets the color of padded area.
The 'bgcolor' property is a color and may be specified as:
- A hex string (e.g. '#ff0000')
- An rgb/rgba string (e.g. 'rgb(255,0,0)')
- An hsl/hsla string (e.g. 'hsl(0,100%,50%)')
- An hsv/hsva string (e.g. 'hsv(0,100%,100%)')
- A named CSS color:
aliceblue, antiquewhite, aqua, aquamarine, azure,
beige, bisque, black, blanchedalmond, blue,
blueviolet, brown, burlywood, cadetblue,
chartreuse, chocolate, coral, cornflowerblue,
cornsilk, crimson, cyan, darkblue, darkcyan,
darkgoldenrod, darkgray, darkgrey, darkgreen,
darkkhaki, darkmagenta, darkolivegreen, darkorange,
darkorchid, darkred, darksalmon, darkseagreen,
darkslateblue, darkslategray, darkslategrey,
darkturquoise, darkviolet, deeppink, deepskyblue,
dimgray, dimgrey, dodgerblue, firebrick,
floralwhite, forestgreen, fuchsia, gainsboro,
ghostwhite, gold, goldenrod, gray, grey, green,
greenyellow, honeydew, hotpink, indianred, indigo,
ivory, khaki, lavender, lavenderblush, lawngreen,
lemonchiffon, lightblue, lightcoral, lightcyan,
lightgoldenrodyellow, lightgray, lightgrey,
lightgreen, lightpink, lightsalmon, lightseagreen,
lightskyblue, lightslategray, lightslategrey,
lightsteelblue, lightyellow, lime, limegreen,
linen, magenta, maroon, mediumaquamarine,
mediumblue, mediumorchid, mediumpurple,
mediumseagreen, mediumslateblue, mediumspringgreen,
mediumturquoise, mediumvioletred, midnightblue,
mintcream, mistyrose, moccasin, navajowhite, navy,
oldlace, olive, olivedrab, orange, orangered,
orchid, palegoldenrod, palegreen, paleturquoise,
palevioletred, papayawhip, peachpuff, peru, pink,
plum, powderblue, purple, red, rosybrown,
royalblue, rebeccapurple, saddlebrown, salmon,
sandybrown, seagreen, seashell, sienna, silver,
skyblue, slateblue, slategray, slategrey, snow,
springgreen, steelblue, tan, teal, thistle, tomato,
turquoise, violet, wheat, white, whitesmoke,
yellow, yellowgreen
Returns
-------
str
|
Sets the color of padded area.
The 'bgcolor' property is a color and may be specified as:
- A hex string (e.g. '#ff0000')
- An rgb/rgba string (e.g. 'rgb(255,0,0)')
- An hsl/hsla string (e.g. 'hsl(0,100%,50%)')
- An hsv/hsva string (e.g. 'hsv(0,100%,100%)')
- A named CSS color:
aliceblue, antiquewhite, aqua, aquamarine, azure,
beige, bisque, black, blanchedalmond, blue,
blueviolet, brown, burlywood, cadetblue,
chartreuse, chocolate, coral, cornflowerblue,
cornsilk, crimson, cyan, darkblue, darkcyan,
darkgoldenrod, darkgray, darkgrey, darkgreen,
darkkhaki, darkmagenta, darkolivegreen, darkorange,
darkorchid, darkred, darksalmon, darkseagreen,
darkslateblue, darkslategray, darkslategrey,
darkturquoise, darkviolet, deeppink, deepskyblue,
dimgray, dimgrey, dodgerblue, firebrick,
floralwhite, forestgreen, fuchsia, gainsboro,
ghostwhite, gold, goldenrod, gray, grey, green,
greenyellow, honeydew, hotpink, indianred, indigo,
ivory, khaki, lavender, lavenderblush, lawngreen,
lemonchiffon, lightblue, lightcoral, lightcyan,
lightgoldenrodyellow, lightgray, lightgrey,
lightgreen, lightpink, lightsalmon, lightseagreen,
lightskyblue, lightslategray, lightslategrey,
lightsteelblue, lightyellow, lime, limegreen,
linen, magenta, maroon, mediumaquamarine,
mediumblue, mediumorchid, mediumpurple,
mediumseagreen, mediumslateblue, mediumspringgreen,
mediumturquoise, mediumvioletred, midnightblue,
mintcream, mistyrose, moccasin, navajowhite, navy,
oldlace, olive, olivedrab, orange, orangered,
orchid, palegoldenrod, palegreen, paleturquoise,
palevioletred, papayawhip, peachpuff, peru, pink,
plum, powderblue, purple, red, rosybrown,
royalblue, rebeccapurple, saddlebrown, salmon,
sandybrown, seagreen, seashell, sienna, silver,
skyblue, slateblue, slategray, slategrey, snow,
springgreen, steelblue, tan, teal, thistle, tomato,
turquoise, violet, wheat, white, whitesmoke,
yellow, yellowgreen | def bgcolor(self):
"""
Sets the color of padded area.
The 'bgcolor' property is a color and may be specified as:
- A hex string (e.g. '#ff0000')
- An rgb/rgba string (e.g. 'rgb(255,0,0)')
- An hsl/hsla string (e.g. 'hsl(0,100%,50%)')
- An hsv/hsva string (e.g. 'hsv(0,100%,100%)')
- A named CSS color:
aliceblue, antiquewhite, aqua, aquamarine, azure,
beige, bisque, black, blanchedalmond, blue,
blueviolet, brown, burlywood, cadetblue,
chartreuse, chocolate, coral, cornflowerblue,
cornsilk, crimson, cyan, darkblue, darkcyan,
darkgoldenrod, darkgray, darkgrey, darkgreen,
darkkhaki, darkmagenta, darkolivegreen, darkorange,
darkorchid, darkred, darksalmon, darkseagreen,
darkslateblue, darkslategray, darkslategrey,
darkturquoise, darkviolet, deeppink, deepskyblue,
dimgray, dimgrey, dodgerblue, firebrick,
floralwhite, forestgreen, fuchsia, gainsboro,
ghostwhite, gold, goldenrod, gray, grey, green,
greenyellow, honeydew, hotpink, indianred, indigo,
ivory, khaki, lavender, lavenderblush, lawngreen,
lemonchiffon, lightblue, lightcoral, lightcyan,
lightgoldenrodyellow, lightgray, lightgrey,
lightgreen, lightpink, lightsalmon, lightseagreen,
lightskyblue, lightslategray, lightslategrey,
lightsteelblue, lightyellow, lime, limegreen,
linen, magenta, maroon, mediumaquamarine,
mediumblue, mediumorchid, mediumpurple,
mediumseagreen, mediumslateblue, mediumspringgreen,
mediumturquoise, mediumvioletred, midnightblue,
mintcream, mistyrose, moccasin, navajowhite, navy,
oldlace, olive, olivedrab, orange, orangered,
orchid, palegoldenrod, palegreen, paleturquoise,
palevioletred, papayawhip, peachpuff, peru, pink,
plum, powderblue, purple, red, rosybrown,
royalblue, rebeccapurple, saddlebrown, salmon,
sandybrown, seagreen, seashell, sienna, silver,
skyblue, slateblue, slategray, slategrey, snow,
springgreen, steelblue, tan, teal, thistle, tomato,
turquoise, violet, wheat, white, whitesmoke,
yellow, yellowgreen
Returns
-------
str
"""
return self["bgcolor"] | [
"def",
"bgcolor",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"bgcolor\"",
"]"
] | [
59,
4
] | [
109,
30
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.bordercolor | (self) |
Sets the axis line color.
The 'bordercolor' property is a color and may be specified as:
- A hex string (e.g. '#ff0000')
- An rgb/rgba string (e.g. 'rgb(255,0,0)')
- An hsl/hsla string (e.g. 'hsl(0,100%,50%)')
- An hsv/hsva string (e.g. 'hsv(0,100%,100%)')
- A named CSS color:
aliceblue, antiquewhite, aqua, aquamarine, azure,
beige, bisque, black, blanchedalmond, blue,
blueviolet, brown, burlywood, cadetblue,
chartreuse, chocolate, coral, cornflowerblue,
cornsilk, crimson, cyan, darkblue, darkcyan,
darkgoldenrod, darkgray, darkgrey, darkgreen,
darkkhaki, darkmagenta, darkolivegreen, darkorange,
darkorchid, darkred, darksalmon, darkseagreen,
darkslateblue, darkslategray, darkslategrey,
darkturquoise, darkviolet, deeppink, deepskyblue,
dimgray, dimgrey, dodgerblue, firebrick,
floralwhite, forestgreen, fuchsia, gainsboro,
ghostwhite, gold, goldenrod, gray, grey, green,
greenyellow, honeydew, hotpink, indianred, indigo,
ivory, khaki, lavender, lavenderblush, lawngreen,
lemonchiffon, lightblue, lightcoral, lightcyan,
lightgoldenrodyellow, lightgray, lightgrey,
lightgreen, lightpink, lightsalmon, lightseagreen,
lightskyblue, lightslategray, lightslategrey,
lightsteelblue, lightyellow, lime, limegreen,
linen, magenta, maroon, mediumaquamarine,
mediumblue, mediumorchid, mediumpurple,
mediumseagreen, mediumslateblue, mediumspringgreen,
mediumturquoise, mediumvioletred, midnightblue,
mintcream, mistyrose, moccasin, navajowhite, navy,
oldlace, olive, olivedrab, orange, orangered,
orchid, palegoldenrod, palegreen, paleturquoise,
palevioletred, papayawhip, peachpuff, peru, pink,
plum, powderblue, purple, red, rosybrown,
royalblue, rebeccapurple, saddlebrown, salmon,
sandybrown, seagreen, seashell, sienna, silver,
skyblue, slateblue, slategray, slategrey, snow,
springgreen, steelblue, tan, teal, thistle, tomato,
turquoise, violet, wheat, white, whitesmoke,
yellow, yellowgreen
Returns
-------
str
|
Sets the axis line color.
The 'bordercolor' property is a color and may be specified as:
- A hex string (e.g. '#ff0000')
- An rgb/rgba string (e.g. 'rgb(255,0,0)')
- An hsl/hsla string (e.g. 'hsl(0,100%,50%)')
- An hsv/hsva string (e.g. 'hsv(0,100%,100%)')
- A named CSS color:
aliceblue, antiquewhite, aqua, aquamarine, azure,
beige, bisque, black, blanchedalmond, blue,
blueviolet, brown, burlywood, cadetblue,
chartreuse, chocolate, coral, cornflowerblue,
cornsilk, crimson, cyan, darkblue, darkcyan,
darkgoldenrod, darkgray, darkgrey, darkgreen,
darkkhaki, darkmagenta, darkolivegreen, darkorange,
darkorchid, darkred, darksalmon, darkseagreen,
darkslateblue, darkslategray, darkslategrey,
darkturquoise, darkviolet, deeppink, deepskyblue,
dimgray, dimgrey, dodgerblue, firebrick,
floralwhite, forestgreen, fuchsia, gainsboro,
ghostwhite, gold, goldenrod, gray, grey, green,
greenyellow, honeydew, hotpink, indianred, indigo,
ivory, khaki, lavender, lavenderblush, lawngreen,
lemonchiffon, lightblue, lightcoral, lightcyan,
lightgoldenrodyellow, lightgray, lightgrey,
lightgreen, lightpink, lightsalmon, lightseagreen,
lightskyblue, lightslategray, lightslategrey,
lightsteelblue, lightyellow, lime, limegreen,
linen, magenta, maroon, mediumaquamarine,
mediumblue, mediumorchid, mediumpurple,
mediumseagreen, mediumslateblue, mediumspringgreen,
mediumturquoise, mediumvioletred, midnightblue,
mintcream, mistyrose, moccasin, navajowhite, navy,
oldlace, olive, olivedrab, orange, orangered,
orchid, palegoldenrod, palegreen, paleturquoise,
palevioletred, papayawhip, peachpuff, peru, pink,
plum, powderblue, purple, red, rosybrown,
royalblue, rebeccapurple, saddlebrown, salmon,
sandybrown, seagreen, seashell, sienna, silver,
skyblue, slateblue, slategray, slategrey, snow,
springgreen, steelblue, tan, teal, thistle, tomato,
turquoise, violet, wheat, white, whitesmoke,
yellow, yellowgreen | def bordercolor(self):
"""
Sets the axis line color.
The 'bordercolor' property is a color and may be specified as:
- A hex string (e.g. '#ff0000')
- An rgb/rgba string (e.g. 'rgb(255,0,0)')
- An hsl/hsla string (e.g. 'hsl(0,100%,50%)')
- An hsv/hsva string (e.g. 'hsv(0,100%,100%)')
- A named CSS color:
aliceblue, antiquewhite, aqua, aquamarine, azure,
beige, bisque, black, blanchedalmond, blue,
blueviolet, brown, burlywood, cadetblue,
chartreuse, chocolate, coral, cornflowerblue,
cornsilk, crimson, cyan, darkblue, darkcyan,
darkgoldenrod, darkgray, darkgrey, darkgreen,
darkkhaki, darkmagenta, darkolivegreen, darkorange,
darkorchid, darkred, darksalmon, darkseagreen,
darkslateblue, darkslategray, darkslategrey,
darkturquoise, darkviolet, deeppink, deepskyblue,
dimgray, dimgrey, dodgerblue, firebrick,
floralwhite, forestgreen, fuchsia, gainsboro,
ghostwhite, gold, goldenrod, gray, grey, green,
greenyellow, honeydew, hotpink, indianred, indigo,
ivory, khaki, lavender, lavenderblush, lawngreen,
lemonchiffon, lightblue, lightcoral, lightcyan,
lightgoldenrodyellow, lightgray, lightgrey,
lightgreen, lightpink, lightsalmon, lightseagreen,
lightskyblue, lightslategray, lightslategrey,
lightsteelblue, lightyellow, lime, limegreen,
linen, magenta, maroon, mediumaquamarine,
mediumblue, mediumorchid, mediumpurple,
mediumseagreen, mediumslateblue, mediumspringgreen,
mediumturquoise, mediumvioletred, midnightblue,
mintcream, mistyrose, moccasin, navajowhite, navy,
oldlace, olive, olivedrab, orange, orangered,
orchid, palegoldenrod, palegreen, paleturquoise,
palevioletred, papayawhip, peachpuff, peru, pink,
plum, powderblue, purple, red, rosybrown,
royalblue, rebeccapurple, saddlebrown, salmon,
sandybrown, seagreen, seashell, sienna, silver,
skyblue, slateblue, slategray, slategrey, snow,
springgreen, steelblue, tan, teal, thistle, tomato,
turquoise, violet, wheat, white, whitesmoke,
yellow, yellowgreen
Returns
-------
str
"""
return self["bordercolor"] | [
"def",
"bordercolor",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"bordercolor\"",
"]"
] | [
118,
4
] | [
168,
34
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.borderwidth | (self) |
Sets the width (in px) or the border enclosing this color bar.
The 'borderwidth' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
|
Sets the width (in px) or the border enclosing this color bar.
The 'borderwidth' property is a number and may be specified as:
- An int or float in the interval [0, inf] | def borderwidth(self):
"""
Sets the width (in px) or the border enclosing this color bar.
The 'borderwidth' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
"""
return self["borderwidth"] | [
"def",
"borderwidth",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"borderwidth\"",
"]"
] | [
177,
4
] | [
188,
34
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.dtick | (self) |
Sets the step in-between ticks on this axis. Use with `tick0`.
Must be a positive number, or special strings available to
"log" and "date" axes. If the axis `type` is "log", then ticks
are set every 10^(n*dtick) where n is the tick number. For
example, to set a tick mark at 1, 10, 100, 1000, ... set dtick
to 1. To set tick marks at 1, 100, 10000, ... set dtick to 2.
To set tick marks at 1, 5, 25, 125, 625, 3125, ... set dtick to
log_10(5), or 0.69897000433. "log" has several special values;
"L<f>", where `f` is a positive number, gives ticks linearly
spaced in value (but not position). For example `tick0` = 0.1,
`dtick` = "L0.5" will put ticks at 0.1, 0.6, 1.1, 1.6 etc. To
show powers of 10 plus small digits between, use "D1" (all
digits) or "D2" (only 2 and 5). `tick0` is ignored for "D1" and
"D2". If the axis `type` is "date", then you must convert the
time to milliseconds. For example, to set the interval between
ticks to one day, set `dtick` to 86400000.0. "date" also has
special values "M<n>" gives ticks spaced by a number of months.
`n` must be a positive integer. To set ticks on the 15th of
every third month, set `tick0` to "2000-01-15" and `dtick` to
"M3". To set ticks every 4 years, set `dtick` to "M48"
The 'dtick' property accepts values of any type
Returns
-------
Any
|
Sets the step in-between ticks on this axis. Use with `tick0`.
Must be a positive number, or special strings available to
"log" and "date" axes. If the axis `type` is "log", then ticks
are set every 10^(n*dtick) where n is the tick number. For
example, to set a tick mark at 1, 10, 100, 1000, ... set dtick
to 1. To set tick marks at 1, 100, 10000, ... set dtick to 2.
To set tick marks at 1, 5, 25, 125, 625, 3125, ... set dtick to
log_10(5), or 0.69897000433. "log" has several special values;
"L<f>", where `f` is a positive number, gives ticks linearly
spaced in value (but not position). For example `tick0` = 0.1,
`dtick` = "L0.5" will put ticks at 0.1, 0.6, 1.1, 1.6 etc. To
show powers of 10 plus small digits between, use "D1" (all
digits) or "D2" (only 2 and 5). `tick0` is ignored for "D1" and
"D2". If the axis `type` is "date", then you must convert the
time to milliseconds. For example, to set the interval between
ticks to one day, set `dtick` to 86400000.0. "date" also has
special values "M<n>" gives ticks spaced by a number of months.
`n` must be a positive integer. To set ticks on the 15th of
every third month, set `tick0` to "2000-01-15" and `dtick` to
"M3". To set ticks every 4 years, set `dtick` to "M48"
The 'dtick' property accepts values of any type | def dtick(self):
"""
Sets the step in-between ticks on this axis. Use with `tick0`.
Must be a positive number, or special strings available to
"log" and "date" axes. If the axis `type` is "log", then ticks
are set every 10^(n*dtick) where n is the tick number. For
example, to set a tick mark at 1, 10, 100, 1000, ... set dtick
to 1. To set tick marks at 1, 100, 10000, ... set dtick to 2.
To set tick marks at 1, 5, 25, 125, 625, 3125, ... set dtick to
log_10(5), or 0.69897000433. "log" has several special values;
"L<f>", where `f` is a positive number, gives ticks linearly
spaced in value (but not position). For example `tick0` = 0.1,
`dtick` = "L0.5" will put ticks at 0.1, 0.6, 1.1, 1.6 etc. To
show powers of 10 plus small digits between, use "D1" (all
digits) or "D2" (only 2 and 5). `tick0` is ignored for "D1" and
"D2". If the axis `type` is "date", then you must convert the
time to milliseconds. For example, to set the interval between
ticks to one day, set `dtick` to 86400000.0. "date" also has
special values "M<n>" gives ticks spaced by a number of months.
`n` must be a positive integer. To set ticks on the 15th of
every third month, set `tick0` to "2000-01-15" and `dtick` to
"M3". To set ticks every 4 years, set `dtick` to "M48"
The 'dtick' property accepts values of any type
Returns
-------
Any
"""
return self["dtick"] | [
"def",
"dtick",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"dtick\"",
"]"
] | [
197,
4
] | [
226,
28
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.exponentformat | (self) |
Determines a formatting rule for the tick exponents. For
example, consider the number 1,000,000,000. If "none", it
appears as 1,000,000,000. If "e", 1e+9. If "E", 1E+9. If
"power", 1x10^9 (with 9 in a super script). If "SI", 1G. If
"B", 1B.
The 'exponentformat' property is an enumeration that may be specified as:
- One of the following enumeration values:
['none', 'e', 'E', 'power', 'SI', 'B']
Returns
-------
Any
|
Determines a formatting rule for the tick exponents. For
example, consider the number 1,000,000,000. If "none", it
appears as 1,000,000,000. If "e", 1e+9. If "E", 1E+9. If
"power", 1x10^9 (with 9 in a super script). If "SI", 1G. If
"B", 1B.
The 'exponentformat' property is an enumeration that may be specified as:
- One of the following enumeration values:
['none', 'e', 'E', 'power', 'SI', 'B'] | def exponentformat(self):
"""
Determines a formatting rule for the tick exponents. For
example, consider the number 1,000,000,000. If "none", it
appears as 1,000,000,000. If "e", 1e+9. If "E", 1E+9. If
"power", 1x10^9 (with 9 in a super script). If "SI", 1G. If
"B", 1B.
The 'exponentformat' property is an enumeration that may be specified as:
- One of the following enumeration values:
['none', 'e', 'E', 'power', 'SI', 'B']
Returns
-------
Any
"""
return self["exponentformat"] | [
"def",
"exponentformat",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"exponentformat\"",
"]"
] | [
235,
4
] | [
251,
37
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.len | (self) |
Sets the length of the color bar This measure excludes the
padding of both ends. That is, the color bar length is this
length minus the padding on both ends.
The 'len' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
|
Sets the length of the color bar This measure excludes the
padding of both ends. That is, the color bar length is this
length minus the padding on both ends.
The 'len' property is a number and may be specified as:
- An int or float in the interval [0, inf] | def len(self):
"""
Sets the length of the color bar This measure excludes the
padding of both ends. That is, the color bar length is this
length minus the padding on both ends.
The 'len' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
"""
return self["len"] | [
"def",
"len",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"len\"",
"]"
] | [
260,
4
] | [
273,
26
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.lenmode | (self) |
Determines whether this color bar's length (i.e. the measure in
the color variation direction) is set in units of plot
"fraction" or in *pixels. Use `len` to set the value.
The 'lenmode' property is an enumeration that may be specified as:
- One of the following enumeration values:
['fraction', 'pixels']
Returns
-------
Any
|
Determines whether this color bar's length (i.e. the measure in
the color variation direction) is set in units of plot
"fraction" or in *pixels. Use `len` to set the value.
The 'lenmode' property is an enumeration that may be specified as:
- One of the following enumeration values:
['fraction', 'pixels'] | def lenmode(self):
"""
Determines whether this color bar's length (i.e. the measure in
the color variation direction) is set in units of plot
"fraction" or in *pixels. Use `len` to set the value.
The 'lenmode' property is an enumeration that may be specified as:
- One of the following enumeration values:
['fraction', 'pixels']
Returns
-------
Any
"""
return self["lenmode"] | [
"def",
"lenmode",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"lenmode\"",
"]"
] | [
282,
4
] | [
296,
30
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.nticks | (self) |
Specifies the maximum number of ticks for the particular axis.
The actual number of ticks will be chosen automatically to be
less than or equal to `nticks`. Has an effect only if
`tickmode` is set to "auto".
The 'nticks' property is a integer and may be specified as:
- An int (or float that will be cast to an int)
in the interval [0, 9223372036854775807]
Returns
-------
int
|
Specifies the maximum number of ticks for the particular axis.
The actual number of ticks will be chosen automatically to be
less than or equal to `nticks`. Has an effect only if
`tickmode` is set to "auto".
The 'nticks' property is a integer and may be specified as:
- An int (or float that will be cast to an int)
in the interval [0, 9223372036854775807] | def nticks(self):
"""
Specifies the maximum number of ticks for the particular axis.
The actual number of ticks will be chosen automatically to be
less than or equal to `nticks`. Has an effect only if
`tickmode` is set to "auto".
The 'nticks' property is a integer and may be specified as:
- An int (or float that will be cast to an int)
in the interval [0, 9223372036854775807]
Returns
-------
int
"""
return self["nticks"] | [
"def",
"nticks",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"nticks\"",
"]"
] | [
305,
4
] | [
320,
29
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.outlinecolor | (self) |
Sets the axis line color.
The 'outlinecolor' property is a color and may be specified as:
- A hex string (e.g. '#ff0000')
- An rgb/rgba string (e.g. 'rgb(255,0,0)')
- An hsl/hsla string (e.g. 'hsl(0,100%,50%)')
- An hsv/hsva string (e.g. 'hsv(0,100%,100%)')
- A named CSS color:
aliceblue, antiquewhite, aqua, aquamarine, azure,
beige, bisque, black, blanchedalmond, blue,
blueviolet, brown, burlywood, cadetblue,
chartreuse, chocolate, coral, cornflowerblue,
cornsilk, crimson, cyan, darkblue, darkcyan,
darkgoldenrod, darkgray, darkgrey, darkgreen,
darkkhaki, darkmagenta, darkolivegreen, darkorange,
darkorchid, darkred, darksalmon, darkseagreen,
darkslateblue, darkslategray, darkslategrey,
darkturquoise, darkviolet, deeppink, deepskyblue,
dimgray, dimgrey, dodgerblue, firebrick,
floralwhite, forestgreen, fuchsia, gainsboro,
ghostwhite, gold, goldenrod, gray, grey, green,
greenyellow, honeydew, hotpink, indianred, indigo,
ivory, khaki, lavender, lavenderblush, lawngreen,
lemonchiffon, lightblue, lightcoral, lightcyan,
lightgoldenrodyellow, lightgray, lightgrey,
lightgreen, lightpink, lightsalmon, lightseagreen,
lightskyblue, lightslategray, lightslategrey,
lightsteelblue, lightyellow, lime, limegreen,
linen, magenta, maroon, mediumaquamarine,
mediumblue, mediumorchid, mediumpurple,
mediumseagreen, mediumslateblue, mediumspringgreen,
mediumturquoise, mediumvioletred, midnightblue,
mintcream, mistyrose, moccasin, navajowhite, navy,
oldlace, olive, olivedrab, orange, orangered,
orchid, palegoldenrod, palegreen, paleturquoise,
palevioletred, papayawhip, peachpuff, peru, pink,
plum, powderblue, purple, red, rosybrown,
royalblue, rebeccapurple, saddlebrown, salmon,
sandybrown, seagreen, seashell, sienna, silver,
skyblue, slateblue, slategray, slategrey, snow,
springgreen, steelblue, tan, teal, thistle, tomato,
turquoise, violet, wheat, white, whitesmoke,
yellow, yellowgreen
Returns
-------
str
|
Sets the axis line color.
The 'outlinecolor' property is a color and may be specified as:
- A hex string (e.g. '#ff0000')
- An rgb/rgba string (e.g. 'rgb(255,0,0)')
- An hsl/hsla string (e.g. 'hsl(0,100%,50%)')
- An hsv/hsva string (e.g. 'hsv(0,100%,100%)')
- A named CSS color:
aliceblue, antiquewhite, aqua, aquamarine, azure,
beige, bisque, black, blanchedalmond, blue,
blueviolet, brown, burlywood, cadetblue,
chartreuse, chocolate, coral, cornflowerblue,
cornsilk, crimson, cyan, darkblue, darkcyan,
darkgoldenrod, darkgray, darkgrey, darkgreen,
darkkhaki, darkmagenta, darkolivegreen, darkorange,
darkorchid, darkred, darksalmon, darkseagreen,
darkslateblue, darkslategray, darkslategrey,
darkturquoise, darkviolet, deeppink, deepskyblue,
dimgray, dimgrey, dodgerblue, firebrick,
floralwhite, forestgreen, fuchsia, gainsboro,
ghostwhite, gold, goldenrod, gray, grey, green,
greenyellow, honeydew, hotpink, indianred, indigo,
ivory, khaki, lavender, lavenderblush, lawngreen,
lemonchiffon, lightblue, lightcoral, lightcyan,
lightgoldenrodyellow, lightgray, lightgrey,
lightgreen, lightpink, lightsalmon, lightseagreen,
lightskyblue, lightslategray, lightslategrey,
lightsteelblue, lightyellow, lime, limegreen,
linen, magenta, maroon, mediumaquamarine,
mediumblue, mediumorchid, mediumpurple,
mediumseagreen, mediumslateblue, mediumspringgreen,
mediumturquoise, mediumvioletred, midnightblue,
mintcream, mistyrose, moccasin, navajowhite, navy,
oldlace, olive, olivedrab, orange, orangered,
orchid, palegoldenrod, palegreen, paleturquoise,
palevioletred, papayawhip, peachpuff, peru, pink,
plum, powderblue, purple, red, rosybrown,
royalblue, rebeccapurple, saddlebrown, salmon,
sandybrown, seagreen, seashell, sienna, silver,
skyblue, slateblue, slategray, slategrey, snow,
springgreen, steelblue, tan, teal, thistle, tomato,
turquoise, violet, wheat, white, whitesmoke,
yellow, yellowgreen | def outlinecolor(self):
"""
Sets the axis line color.
The 'outlinecolor' property is a color and may be specified as:
- A hex string (e.g. '#ff0000')
- An rgb/rgba string (e.g. 'rgb(255,0,0)')
- An hsl/hsla string (e.g. 'hsl(0,100%,50%)')
- An hsv/hsva string (e.g. 'hsv(0,100%,100%)')
- A named CSS color:
aliceblue, antiquewhite, aqua, aquamarine, azure,
beige, bisque, black, blanchedalmond, blue,
blueviolet, brown, burlywood, cadetblue,
chartreuse, chocolate, coral, cornflowerblue,
cornsilk, crimson, cyan, darkblue, darkcyan,
darkgoldenrod, darkgray, darkgrey, darkgreen,
darkkhaki, darkmagenta, darkolivegreen, darkorange,
darkorchid, darkred, darksalmon, darkseagreen,
darkslateblue, darkslategray, darkslategrey,
darkturquoise, darkviolet, deeppink, deepskyblue,
dimgray, dimgrey, dodgerblue, firebrick,
floralwhite, forestgreen, fuchsia, gainsboro,
ghostwhite, gold, goldenrod, gray, grey, green,
greenyellow, honeydew, hotpink, indianred, indigo,
ivory, khaki, lavender, lavenderblush, lawngreen,
lemonchiffon, lightblue, lightcoral, lightcyan,
lightgoldenrodyellow, lightgray, lightgrey,
lightgreen, lightpink, lightsalmon, lightseagreen,
lightskyblue, lightslategray, lightslategrey,
lightsteelblue, lightyellow, lime, limegreen,
linen, magenta, maroon, mediumaquamarine,
mediumblue, mediumorchid, mediumpurple,
mediumseagreen, mediumslateblue, mediumspringgreen,
mediumturquoise, mediumvioletred, midnightblue,
mintcream, mistyrose, moccasin, navajowhite, navy,
oldlace, olive, olivedrab, orange, orangered,
orchid, palegoldenrod, palegreen, paleturquoise,
palevioletred, papayawhip, peachpuff, peru, pink,
plum, powderblue, purple, red, rosybrown,
royalblue, rebeccapurple, saddlebrown, salmon,
sandybrown, seagreen, seashell, sienna, silver,
skyblue, slateblue, slategray, slategrey, snow,
springgreen, steelblue, tan, teal, thistle, tomato,
turquoise, violet, wheat, white, whitesmoke,
yellow, yellowgreen
Returns
-------
str
"""
return self["outlinecolor"] | [
"def",
"outlinecolor",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"outlinecolor\"",
"]"
] | [
329,
4
] | [
379,
35
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.outlinewidth | (self) |
Sets the width (in px) of the axis line.
The 'outlinewidth' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
|
Sets the width (in px) of the axis line.
The 'outlinewidth' property is a number and may be specified as:
- An int or float in the interval [0, inf] | def outlinewidth(self):
"""
Sets the width (in px) of the axis line.
The 'outlinewidth' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
"""
return self["outlinewidth"] | [
"def",
"outlinewidth",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"outlinewidth\"",
"]"
] | [
388,
4
] | [
399,
35
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.separatethousands | (self) |
If "true", even 4-digit integers are separated
The 'separatethousands' property must be specified as a bool
(either True, or False)
Returns
-------
bool
|
If "true", even 4-digit integers are separated
The 'separatethousands' property must be specified as a bool
(either True, or False) | def separatethousands(self):
"""
If "true", even 4-digit integers are separated
The 'separatethousands' property must be specified as a bool
(either True, or False)
Returns
-------
bool
"""
return self["separatethousands"] | [
"def",
"separatethousands",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"separatethousands\"",
"]"
] | [
408,
4
] | [
419,
40
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.showexponent | (self) |
If "all", all exponents are shown besides their significands.
If "first", only the exponent of the first tick is shown. If
"last", only the exponent of the last tick is shown. If "none",
no exponents appear.
The 'showexponent' property is an enumeration that may be specified as:
- One of the following enumeration values:
['all', 'first', 'last', 'none']
Returns
-------
Any
|
If "all", all exponents are shown besides their significands.
If "first", only the exponent of the first tick is shown. If
"last", only the exponent of the last tick is shown. If "none",
no exponents appear.
The 'showexponent' property is an enumeration that may be specified as:
- One of the following enumeration values:
['all', 'first', 'last', 'none'] | def showexponent(self):
"""
If "all", all exponents are shown besides their significands.
If "first", only the exponent of the first tick is shown. If
"last", only the exponent of the last tick is shown. If "none",
no exponents appear.
The 'showexponent' property is an enumeration that may be specified as:
- One of the following enumeration values:
['all', 'first', 'last', 'none']
Returns
-------
Any
"""
return self["showexponent"] | [
"def",
"showexponent",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"showexponent\"",
"]"
] | [
428,
4
] | [
443,
35
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.showticklabels | (self) |
Determines whether or not the tick labels are drawn.
The 'showticklabels' property must be specified as a bool
(either True, or False)
Returns
-------
bool
|
Determines whether or not the tick labels are drawn.
The 'showticklabels' property must be specified as a bool
(either True, or False) | def showticklabels(self):
"""
Determines whether or not the tick labels are drawn.
The 'showticklabels' property must be specified as a bool
(either True, or False)
Returns
-------
bool
"""
return self["showticklabels"] | [
"def",
"showticklabels",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"showticklabels\"",
"]"
] | [
452,
4
] | [
463,
37
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.showtickprefix | (self) |
If "all", all tick labels are displayed with a prefix. If
"first", only the first tick is displayed with a prefix. If
"last", only the last tick is displayed with a suffix. If
"none", tick prefixes are hidden.
The 'showtickprefix' property is an enumeration that may be specified as:
- One of the following enumeration values:
['all', 'first', 'last', 'none']
Returns
-------
Any
|
If "all", all tick labels are displayed with a prefix. If
"first", only the first tick is displayed with a prefix. If
"last", only the last tick is displayed with a suffix. If
"none", tick prefixes are hidden.
The 'showtickprefix' property is an enumeration that may be specified as:
- One of the following enumeration values:
['all', 'first', 'last', 'none'] | def showtickprefix(self):
"""
If "all", all tick labels are displayed with a prefix. If
"first", only the first tick is displayed with a prefix. If
"last", only the last tick is displayed with a suffix. If
"none", tick prefixes are hidden.
The 'showtickprefix' property is an enumeration that may be specified as:
- One of the following enumeration values:
['all', 'first', 'last', 'none']
Returns
-------
Any
"""
return self["showtickprefix"] | [
"def",
"showtickprefix",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"showtickprefix\"",
"]"
] | [
472,
4
] | [
487,
37
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.showticksuffix | (self) |
Same as `showtickprefix` but for tick suffixes.
The 'showticksuffix' property is an enumeration that may be specified as:
- One of the following enumeration values:
['all', 'first', 'last', 'none']
Returns
-------
Any
|
Same as `showtickprefix` but for tick suffixes.
The 'showticksuffix' property is an enumeration that may be specified as:
- One of the following enumeration values:
['all', 'first', 'last', 'none'] | def showticksuffix(self):
"""
Same as `showtickprefix` but for tick suffixes.
The 'showticksuffix' property is an enumeration that may be specified as:
- One of the following enumeration values:
['all', 'first', 'last', 'none']
Returns
-------
Any
"""
return self["showticksuffix"] | [
"def",
"showticksuffix",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"showticksuffix\"",
"]"
] | [
496,
4
] | [
508,
37
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.thickness | (self) |
Sets the thickness of the color bar This measure excludes the
size of the padding, ticks and labels.
The 'thickness' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
|
Sets the thickness of the color bar This measure excludes the
size of the padding, ticks and labels.
The 'thickness' property is a number and may be specified as:
- An int or float in the interval [0, inf] | def thickness(self):
"""
Sets the thickness of the color bar This measure excludes the
size of the padding, ticks and labels.
The 'thickness' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
"""
return self["thickness"] | [
"def",
"thickness",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"thickness\"",
"]"
] | [
517,
4
] | [
529,
32
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.thicknessmode | (self) |
Determines whether this color bar's thickness (i.e. the measure
in the constant color direction) is set in units of plot
"fraction" or in "pixels". Use `thickness` to set the value.
The 'thicknessmode' property is an enumeration that may be specified as:
- One of the following enumeration values:
['fraction', 'pixels']
Returns
-------
Any
|
Determines whether this color bar's thickness (i.e. the measure
in the constant color direction) is set in units of plot
"fraction" or in "pixels". Use `thickness` to set the value.
The 'thicknessmode' property is an enumeration that may be specified as:
- One of the following enumeration values:
['fraction', 'pixels'] | def thicknessmode(self):
"""
Determines whether this color bar's thickness (i.e. the measure
in the constant color direction) is set in units of plot
"fraction" or in "pixels". Use `thickness` to set the value.
The 'thicknessmode' property is an enumeration that may be specified as:
- One of the following enumeration values:
['fraction', 'pixels']
Returns
-------
Any
"""
return self["thicknessmode"] | [
"def",
"thicknessmode",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"thicknessmode\"",
"]"
] | [
538,
4
] | [
552,
36
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.tick0 | (self) |
Sets the placement of the first tick on this axis. Use with
`dtick`. If the axis `type` is "log", then you must take the
log of your starting tick (e.g. to set the starting tick to
100, set the `tick0` to 2) except when `dtick`=*L<f>* (see
`dtick` for more info). If the axis `type` is "date", it should
be a date string, like date data. If the axis `type` is
"category", it should be a number, using the scale where each
category is assigned a serial number from zero in the order it
appears.
The 'tick0' property accepts values of any type
Returns
-------
Any
|
Sets the placement of the first tick on this axis. Use with
`dtick`. If the axis `type` is "log", then you must take the
log of your starting tick (e.g. to set the starting tick to
100, set the `tick0` to 2) except when `dtick`=*L<f>* (see
`dtick` for more info). If the axis `type` is "date", it should
be a date string, like date data. If the axis `type` is
"category", it should be a number, using the scale where each
category is assigned a serial number from zero in the order it
appears.
The 'tick0' property accepts values of any type | def tick0(self):
"""
Sets the placement of the first tick on this axis. Use with
`dtick`. If the axis `type` is "log", then you must take the
log of your starting tick (e.g. to set the starting tick to
100, set the `tick0` to 2) except when `dtick`=*L<f>* (see
`dtick` for more info). If the axis `type` is "date", it should
be a date string, like date data. If the axis `type` is
"category", it should be a number, using the scale where each
category is assigned a serial number from zero in the order it
appears.
The 'tick0' property accepts values of any type
Returns
-------
Any
"""
return self["tick0"] | [
"def",
"tick0",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"tick0\"",
"]"
] | [
561,
4
] | [
579,
28
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.tickangle | (self) |
Sets the angle of the tick labels with respect to the
horizontal. For example, a `tickangle` of -90 draws the tick
labels vertically.
The 'tickangle' property is a angle (in degrees) that may be
specified as a number between -180 and 180. Numeric values outside this
range are converted to the equivalent value
(e.g. 270 is converted to -90).
Returns
-------
int|float
|
Sets the angle of the tick labels with respect to the
horizontal. For example, a `tickangle` of -90 draws the tick
labels vertically.
The 'tickangle' property is a angle (in degrees) that may be
specified as a number between -180 and 180. Numeric values outside this
range are converted to the equivalent value
(e.g. 270 is converted to -90). | def tickangle(self):
"""
Sets the angle of the tick labels with respect to the
horizontal. For example, a `tickangle` of -90 draws the tick
labels vertically.
The 'tickangle' property is a angle (in degrees) that may be
specified as a number between -180 and 180. Numeric values outside this
range are converted to the equivalent value
(e.g. 270 is converted to -90).
Returns
-------
int|float
"""
return self["tickangle"] | [
"def",
"tickangle",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"tickangle\"",
"]"
] | [
588,
4
] | [
603,
32
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.tickcolor | (self) |
Sets the tick color.
The 'tickcolor' property is a color and may be specified as:
- A hex string (e.g. '#ff0000')
- An rgb/rgba string (e.g. 'rgb(255,0,0)')
- An hsl/hsla string (e.g. 'hsl(0,100%,50%)')
- An hsv/hsva string (e.g. 'hsv(0,100%,100%)')
- A named CSS color:
aliceblue, antiquewhite, aqua, aquamarine, azure,
beige, bisque, black, blanchedalmond, blue,
blueviolet, brown, burlywood, cadetblue,
chartreuse, chocolate, coral, cornflowerblue,
cornsilk, crimson, cyan, darkblue, darkcyan,
darkgoldenrod, darkgray, darkgrey, darkgreen,
darkkhaki, darkmagenta, darkolivegreen, darkorange,
darkorchid, darkred, darksalmon, darkseagreen,
darkslateblue, darkslategray, darkslategrey,
darkturquoise, darkviolet, deeppink, deepskyblue,
dimgray, dimgrey, dodgerblue, firebrick,
floralwhite, forestgreen, fuchsia, gainsboro,
ghostwhite, gold, goldenrod, gray, grey, green,
greenyellow, honeydew, hotpink, indianred, indigo,
ivory, khaki, lavender, lavenderblush, lawngreen,
lemonchiffon, lightblue, lightcoral, lightcyan,
lightgoldenrodyellow, lightgray, lightgrey,
lightgreen, lightpink, lightsalmon, lightseagreen,
lightskyblue, lightslategray, lightslategrey,
lightsteelblue, lightyellow, lime, limegreen,
linen, magenta, maroon, mediumaquamarine,
mediumblue, mediumorchid, mediumpurple,
mediumseagreen, mediumslateblue, mediumspringgreen,
mediumturquoise, mediumvioletred, midnightblue,
mintcream, mistyrose, moccasin, navajowhite, navy,
oldlace, olive, olivedrab, orange, orangered,
orchid, palegoldenrod, palegreen, paleturquoise,
palevioletred, papayawhip, peachpuff, peru, pink,
plum, powderblue, purple, red, rosybrown,
royalblue, rebeccapurple, saddlebrown, salmon,
sandybrown, seagreen, seashell, sienna, silver,
skyblue, slateblue, slategray, slategrey, snow,
springgreen, steelblue, tan, teal, thistle, tomato,
turquoise, violet, wheat, white, whitesmoke,
yellow, yellowgreen
Returns
-------
str
|
Sets the tick color.
The 'tickcolor' property is a color and may be specified as:
- A hex string (e.g. '#ff0000')
- An rgb/rgba string (e.g. 'rgb(255,0,0)')
- An hsl/hsla string (e.g. 'hsl(0,100%,50%)')
- An hsv/hsva string (e.g. 'hsv(0,100%,100%)')
- A named CSS color:
aliceblue, antiquewhite, aqua, aquamarine, azure,
beige, bisque, black, blanchedalmond, blue,
blueviolet, brown, burlywood, cadetblue,
chartreuse, chocolate, coral, cornflowerblue,
cornsilk, crimson, cyan, darkblue, darkcyan,
darkgoldenrod, darkgray, darkgrey, darkgreen,
darkkhaki, darkmagenta, darkolivegreen, darkorange,
darkorchid, darkred, darksalmon, darkseagreen,
darkslateblue, darkslategray, darkslategrey,
darkturquoise, darkviolet, deeppink, deepskyblue,
dimgray, dimgrey, dodgerblue, firebrick,
floralwhite, forestgreen, fuchsia, gainsboro,
ghostwhite, gold, goldenrod, gray, grey, green,
greenyellow, honeydew, hotpink, indianred, indigo,
ivory, khaki, lavender, lavenderblush, lawngreen,
lemonchiffon, lightblue, lightcoral, lightcyan,
lightgoldenrodyellow, lightgray, lightgrey,
lightgreen, lightpink, lightsalmon, lightseagreen,
lightskyblue, lightslategray, lightslategrey,
lightsteelblue, lightyellow, lime, limegreen,
linen, magenta, maroon, mediumaquamarine,
mediumblue, mediumorchid, mediumpurple,
mediumseagreen, mediumslateblue, mediumspringgreen,
mediumturquoise, mediumvioletred, midnightblue,
mintcream, mistyrose, moccasin, navajowhite, navy,
oldlace, olive, olivedrab, orange, orangered,
orchid, palegoldenrod, palegreen, paleturquoise,
palevioletred, papayawhip, peachpuff, peru, pink,
plum, powderblue, purple, red, rosybrown,
royalblue, rebeccapurple, saddlebrown, salmon,
sandybrown, seagreen, seashell, sienna, silver,
skyblue, slateblue, slategray, slategrey, snow,
springgreen, steelblue, tan, teal, thistle, tomato,
turquoise, violet, wheat, white, whitesmoke,
yellow, yellowgreen | def tickcolor(self):
"""
Sets the tick color.
The 'tickcolor' property is a color and may be specified as:
- A hex string (e.g. '#ff0000')
- An rgb/rgba string (e.g. 'rgb(255,0,0)')
- An hsl/hsla string (e.g. 'hsl(0,100%,50%)')
- An hsv/hsva string (e.g. 'hsv(0,100%,100%)')
- A named CSS color:
aliceblue, antiquewhite, aqua, aquamarine, azure,
beige, bisque, black, blanchedalmond, blue,
blueviolet, brown, burlywood, cadetblue,
chartreuse, chocolate, coral, cornflowerblue,
cornsilk, crimson, cyan, darkblue, darkcyan,
darkgoldenrod, darkgray, darkgrey, darkgreen,
darkkhaki, darkmagenta, darkolivegreen, darkorange,
darkorchid, darkred, darksalmon, darkseagreen,
darkslateblue, darkslategray, darkslategrey,
darkturquoise, darkviolet, deeppink, deepskyblue,
dimgray, dimgrey, dodgerblue, firebrick,
floralwhite, forestgreen, fuchsia, gainsboro,
ghostwhite, gold, goldenrod, gray, grey, green,
greenyellow, honeydew, hotpink, indianred, indigo,
ivory, khaki, lavender, lavenderblush, lawngreen,
lemonchiffon, lightblue, lightcoral, lightcyan,
lightgoldenrodyellow, lightgray, lightgrey,
lightgreen, lightpink, lightsalmon, lightseagreen,
lightskyblue, lightslategray, lightslategrey,
lightsteelblue, lightyellow, lime, limegreen,
linen, magenta, maroon, mediumaquamarine,
mediumblue, mediumorchid, mediumpurple,
mediumseagreen, mediumslateblue, mediumspringgreen,
mediumturquoise, mediumvioletred, midnightblue,
mintcream, mistyrose, moccasin, navajowhite, navy,
oldlace, olive, olivedrab, orange, orangered,
orchid, palegoldenrod, palegreen, paleturquoise,
palevioletred, papayawhip, peachpuff, peru, pink,
plum, powderblue, purple, red, rosybrown,
royalblue, rebeccapurple, saddlebrown, salmon,
sandybrown, seagreen, seashell, sienna, silver,
skyblue, slateblue, slategray, slategrey, snow,
springgreen, steelblue, tan, teal, thistle, tomato,
turquoise, violet, wheat, white, whitesmoke,
yellow, yellowgreen
Returns
-------
str
"""
return self["tickcolor"] | [
"def",
"tickcolor",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"tickcolor\"",
"]"
] | [
612,
4
] | [
662,
32
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.tickfont | (self) |
Sets the color bar's tick label font
The 'tickfont' property is an instance of Tickfont
that may be specified as:
- An instance of :class:`plotly.graph_objs.mesh3d.colorbar.Tickfont`
- A dict of string/value properties that will be passed
to the Tickfont constructor
Supported dict properties:
color
family
HTML font family - the typeface that will be
applied by the web browser. The web browser
will only be able to apply a font if it is
available on the system which it operates.
Provide multiple font families, separated by
commas, to indicate the preference in which to
apply fonts if they aren't available on the
system. The Chart Studio Cloud (at
https://chart-studio.plotly.com or on-premise)
generates images on a server, where only a
select number of fonts are installed and
supported. These include "Arial", "Balto",
"Courier New", "Droid Sans",, "Droid Serif",
"Droid Sans Mono", "Gravitas One", "Old
Standard TT", "Open Sans", "Overpass", "PT Sans
Narrow", "Raleway", "Times New Roman".
size
Returns
-------
plotly.graph_objs.mesh3d.colorbar.Tickfont
|
Sets the color bar's tick label font
The 'tickfont' property is an instance of Tickfont
that may be specified as:
- An instance of :class:`plotly.graph_objs.mesh3d.colorbar.Tickfont`
- A dict of string/value properties that will be passed
to the Tickfont constructor
Supported dict properties:
color
family
HTML font family - the typeface that will be
applied by the web browser. The web browser
will only be able to apply a font if it is
available on the system which it operates.
Provide multiple font families, separated by
commas, to indicate the preference in which to
apply fonts if they aren't available on the
system. The Chart Studio Cloud (at
https://chart-studio.plotly.com or on-premise)
generates images on a server, where only a
select number of fonts are installed and
supported. These include "Arial", "Balto",
"Courier New", "Droid Sans",, "Droid Serif",
"Droid Sans Mono", "Gravitas One", "Old
Standard TT", "Open Sans", "Overpass", "PT Sans
Narrow", "Raleway", "Times New Roman".
size | def tickfont(self):
"""
Sets the color bar's tick label font
The 'tickfont' property is an instance of Tickfont
that may be specified as:
- An instance of :class:`plotly.graph_objs.mesh3d.colorbar.Tickfont`
- A dict of string/value properties that will be passed
to the Tickfont constructor
Supported dict properties:
color
family
HTML font family - the typeface that will be
applied by the web browser. The web browser
will only be able to apply a font if it is
available on the system which it operates.
Provide multiple font families, separated by
commas, to indicate the preference in which to
apply fonts if they aren't available on the
system. The Chart Studio Cloud (at
https://chart-studio.plotly.com or on-premise)
generates images on a server, where only a
select number of fonts are installed and
supported. These include "Arial", "Balto",
"Courier New", "Droid Sans",, "Droid Serif",
"Droid Sans Mono", "Gravitas One", "Old
Standard TT", "Open Sans", "Overpass", "PT Sans
Narrow", "Raleway", "Times New Roman".
size
Returns
-------
plotly.graph_objs.mesh3d.colorbar.Tickfont
"""
return self["tickfont"] | [
"def",
"tickfont",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"tickfont\"",
"]"
] | [
671,
4
] | [
708,
31
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.tickformat | (self) |
Sets the tick label formatting rule using d3 formatting mini-
languages which are very similar to those in Python. For
numbers, see: https://github.com/d3/d3-3.x-api-
reference/blob/master/Formatting.md#d3_format And for dates
see: https://github.com/d3/d3-3.x-api-
reference/blob/master/Time-Formatting.md#format We add one item
to d3's date formatter: "%{n}f" for fractional seconds with n
digits. For example, *2016-10-13 09:15:23.456* with tickformat
"%H~%M~%S.%2f" would display "09~15~23.46"
The 'tickformat' property is a string and must be specified as:
- A string
- A number that will be converted to a string
Returns
-------
str
|
Sets the tick label formatting rule using d3 formatting mini-
languages which are very similar to those in Python. For
numbers, see: https://github.com/d3/d3-3.x-api-
reference/blob/master/Formatting.md#d3_format And for dates
see: https://github.com/d3/d3-3.x-api-
reference/blob/master/Time-Formatting.md#format We add one item
to d3's date formatter: "%{n}f" for fractional seconds with n
digits. For example, *2016-10-13 09:15:23.456* with tickformat
"%H~%M~%S.%2f" would display "09~15~23.46"
The 'tickformat' property is a string and must be specified as:
- A string
- A number that will be converted to a string | def tickformat(self):
"""
Sets the tick label formatting rule using d3 formatting mini-
languages which are very similar to those in Python. For
numbers, see: https://github.com/d3/d3-3.x-api-
reference/blob/master/Formatting.md#d3_format And for dates
see: https://github.com/d3/d3-3.x-api-
reference/blob/master/Time-Formatting.md#format We add one item
to d3's date formatter: "%{n}f" for fractional seconds with n
digits. For example, *2016-10-13 09:15:23.456* with tickformat
"%H~%M~%S.%2f" would display "09~15~23.46"
The 'tickformat' property is a string and must be specified as:
- A string
- A number that will be converted to a string
Returns
-------
str
"""
return self["tickformat"] | [
"def",
"tickformat",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"tickformat\"",
"]"
] | [
717,
4
] | [
737,
33
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.tickformatstops | (self) |
The 'tickformatstops' property is a tuple of instances of
Tickformatstop that may be specified as:
- A list or tuple of instances of plotly.graph_objs.mesh3d.colorbar.Tickformatstop
- A list or tuple of dicts of string/value properties that
will be passed to the Tickformatstop constructor
Supported dict properties:
dtickrange
range [*min*, *max*], where "min", "max" -
dtick values which describe some zoom level, it
is possible to omit "min" or "max" value by
passing "null"
enabled
Determines whether or not this stop is used. If
`false`, this stop is ignored even within its
`dtickrange`.
name
When used in a template, named items are
created in the output figure in addition to any
items the figure already has in this array. You
can modify these items in the output figure by
making your own item with `templateitemname`
matching this `name` alongside your
modifications (including `visible: false` or
`enabled: false` to hide it). Has no effect
outside of a template.
templateitemname
Used to refer to a named item in this array in
the template. Named items from the template
will be created even without a matching item in
the input figure, but you can modify one by
making an item with `templateitemname` matching
its `name`, alongside your modifications
(including `visible: false` or `enabled: false`
to hide it). If there is no template or no
matching item, this item will be hidden unless
you explicitly show it with `visible: true`.
value
string - dtickformat for described zoom level,
the same as "tickformat"
Returns
-------
tuple[plotly.graph_objs.mesh3d.colorbar.Tickformatstop]
|
The 'tickformatstops' property is a tuple of instances of
Tickformatstop that may be specified as:
- A list or tuple of instances of plotly.graph_objs.mesh3d.colorbar.Tickformatstop
- A list or tuple of dicts of string/value properties that
will be passed to the Tickformatstop constructor
Supported dict properties:
dtickrange
range [*min*, *max*], where "min", "max" -
dtick values which describe some zoom level, it
is possible to omit "min" or "max" value by
passing "null"
enabled
Determines whether or not this stop is used. If
`false`, this stop is ignored even within its
`dtickrange`.
name
When used in a template, named items are
created in the output figure in addition to any
items the figure already has in this array. You
can modify these items in the output figure by
making your own item with `templateitemname`
matching this `name` alongside your
modifications (including `visible: false` or
`enabled: false` to hide it). Has no effect
outside of a template.
templateitemname
Used to refer to a named item in this array in
the template. Named items from the template
will be created even without a matching item in
the input figure, but you can modify one by
making an item with `templateitemname` matching
its `name`, alongside your modifications
(including `visible: false` or `enabled: false`
to hide it). If there is no template or no
matching item, this item will be hidden unless
you explicitly show it with `visible: true`.
value
string - dtickformat for described zoom level,
the same as "tickformat" | def tickformatstops(self):
"""
The 'tickformatstops' property is a tuple of instances of
Tickformatstop that may be specified as:
- A list or tuple of instances of plotly.graph_objs.mesh3d.colorbar.Tickformatstop
- A list or tuple of dicts of string/value properties that
will be passed to the Tickformatstop constructor
Supported dict properties:
dtickrange
range [*min*, *max*], where "min", "max" -
dtick values which describe some zoom level, it
is possible to omit "min" or "max" value by
passing "null"
enabled
Determines whether or not this stop is used. If
`false`, this stop is ignored even within its
`dtickrange`.
name
When used in a template, named items are
created in the output figure in addition to any
items the figure already has in this array. You
can modify these items in the output figure by
making your own item with `templateitemname`
matching this `name` alongside your
modifications (including `visible: false` or
`enabled: false` to hide it). Has no effect
outside of a template.
templateitemname
Used to refer to a named item in this array in
the template. Named items from the template
will be created even without a matching item in
the input figure, but you can modify one by
making an item with `templateitemname` matching
its `name`, alongside your modifications
(including `visible: false` or `enabled: false`
to hide it). If there is no template or no
matching item, this item will be hidden unless
you explicitly show it with `visible: true`.
value
string - dtickformat for described zoom level,
the same as "tickformat"
Returns
-------
tuple[plotly.graph_objs.mesh3d.colorbar.Tickformatstop]
"""
return self["tickformatstops"] | [
"def",
"tickformatstops",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"tickformatstops\"",
"]"
] | [
746,
4
] | [
794,
38
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.tickformatstopdefaults | (self) |
When used in a template (as
layout.template.data.mesh3d.colorbar.tickformatstopdefaults),
sets the default property values to use for elements of
mesh3d.colorbar.tickformatstops
The 'tickformatstopdefaults' property is an instance of Tickformatstop
that may be specified as:
- An instance of :class:`plotly.graph_objs.mesh3d.colorbar.Tickformatstop`
- A dict of string/value properties that will be passed
to the Tickformatstop constructor
Supported dict properties:
Returns
-------
plotly.graph_objs.mesh3d.colorbar.Tickformatstop
|
When used in a template (as
layout.template.data.mesh3d.colorbar.tickformatstopdefaults),
sets the default property values to use for elements of
mesh3d.colorbar.tickformatstops
The 'tickformatstopdefaults' property is an instance of Tickformatstop
that may be specified as:
- An instance of :class:`plotly.graph_objs.mesh3d.colorbar.Tickformatstop`
- A dict of string/value properties that will be passed
to the Tickformatstop constructor
Supported dict properties: | def tickformatstopdefaults(self):
"""
When used in a template (as
layout.template.data.mesh3d.colorbar.tickformatstopdefaults),
sets the default property values to use for elements of
mesh3d.colorbar.tickformatstops
The 'tickformatstopdefaults' property is an instance of Tickformatstop
that may be specified as:
- An instance of :class:`plotly.graph_objs.mesh3d.colorbar.Tickformatstop`
- A dict of string/value properties that will be passed
to the Tickformatstop constructor
Supported dict properties:
Returns
-------
plotly.graph_objs.mesh3d.colorbar.Tickformatstop
"""
return self["tickformatstopdefaults"] | [
"def",
"tickformatstopdefaults",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"tickformatstopdefaults\"",
"]"
] | [
803,
4
] | [
822,
45
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.ticklen | (self) |
Sets the tick length (in px).
The 'ticklen' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
|
Sets the tick length (in px).
The 'ticklen' property is a number and may be specified as:
- An int or float in the interval [0, inf] | def ticklen(self):
"""
Sets the tick length (in px).
The 'ticklen' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
"""
return self["ticklen"] | [
"def",
"ticklen",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"ticklen\"",
"]"
] | [
831,
4
] | [
842,
30
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.tickmode | (self) |
Sets the tick mode for this axis. If "auto", the number of
ticks is set via `nticks`. If "linear", the placement of the
ticks is determined by a starting position `tick0` and a tick
step `dtick` ("linear" is the default value if `tick0` and
`dtick` are provided). If "array", the placement of the ticks
is set via `tickvals` and the tick text is `ticktext`. ("array"
is the default value if `tickvals` is provided).
The 'tickmode' property is an enumeration that may be specified as:
- One of the following enumeration values:
['auto', 'linear', 'array']
Returns
-------
Any
|
Sets the tick mode for this axis. If "auto", the number of
ticks is set via `nticks`. If "linear", the placement of the
ticks is determined by a starting position `tick0` and a tick
step `dtick` ("linear" is the default value if `tick0` and
`dtick` are provided). If "array", the placement of the ticks
is set via `tickvals` and the tick text is `ticktext`. ("array"
is the default value if `tickvals` is provided).
The 'tickmode' property is an enumeration that may be specified as:
- One of the following enumeration values:
['auto', 'linear', 'array'] | def tickmode(self):
"""
Sets the tick mode for this axis. If "auto", the number of
ticks is set via `nticks`. If "linear", the placement of the
ticks is determined by a starting position `tick0` and a tick
step `dtick` ("linear" is the default value if `tick0` and
`dtick` are provided). If "array", the placement of the ticks
is set via `tickvals` and the tick text is `ticktext`. ("array"
is the default value if `tickvals` is provided).
The 'tickmode' property is an enumeration that may be specified as:
- One of the following enumeration values:
['auto', 'linear', 'array']
Returns
-------
Any
"""
return self["tickmode"] | [
"def",
"tickmode",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"tickmode\"",
"]"
] | [
851,
4
] | [
869,
31
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.tickprefix | (self) |
Sets a tick label prefix.
The 'tickprefix' property is a string and must be specified as:
- A string
- A number that will be converted to a string
Returns
-------
str
|
Sets a tick label prefix.
The 'tickprefix' property is a string and must be specified as:
- A string
- A number that will be converted to a string | def tickprefix(self):
"""
Sets a tick label prefix.
The 'tickprefix' property is a string and must be specified as:
- A string
- A number that will be converted to a string
Returns
-------
str
"""
return self["tickprefix"] | [
"def",
"tickprefix",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"tickprefix\"",
"]"
] | [
878,
4
] | [
890,
33
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.ticks | (self) |
Determines whether ticks are drawn or not. If "", this axis'
ticks are not drawn. If "outside" ("inside"), this axis' are
drawn outside (inside) the axis lines.
The 'ticks' property is an enumeration that may be specified as:
- One of the following enumeration values:
['outside', 'inside', '']
Returns
-------
Any
|
Determines whether ticks are drawn or not. If "", this axis'
ticks are not drawn. If "outside" ("inside"), this axis' are
drawn outside (inside) the axis lines.
The 'ticks' property is an enumeration that may be specified as:
- One of the following enumeration values:
['outside', 'inside', ''] | def ticks(self):
"""
Determines whether ticks are drawn or not. If "", this axis'
ticks are not drawn. If "outside" ("inside"), this axis' are
drawn outside (inside) the axis lines.
The 'ticks' property is an enumeration that may be specified as:
- One of the following enumeration values:
['outside', 'inside', '']
Returns
-------
Any
"""
return self["ticks"] | [
"def",
"ticks",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"ticks\"",
"]"
] | [
899,
4
] | [
913,
28
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.ticksuffix | (self) |
Sets a tick label suffix.
The 'ticksuffix' property is a string and must be specified as:
- A string
- A number that will be converted to a string
Returns
-------
str
|
Sets a tick label suffix.
The 'ticksuffix' property is a string and must be specified as:
- A string
- A number that will be converted to a string | def ticksuffix(self):
"""
Sets a tick label suffix.
The 'ticksuffix' property is a string and must be specified as:
- A string
- A number that will be converted to a string
Returns
-------
str
"""
return self["ticksuffix"] | [
"def",
"ticksuffix",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"ticksuffix\"",
"]"
] | [
922,
4
] | [
934,
33
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.ticktext | (self) |
Sets the text displayed at the ticks position via `tickvals`.
Only has an effect if `tickmode` is set to "array". Used with
`tickvals`.
The 'ticktext' property is an array that may be specified as a tuple,
list, numpy array, or pandas Series
Returns
-------
numpy.ndarray
|
Sets the text displayed at the ticks position via `tickvals`.
Only has an effect if `tickmode` is set to "array". Used with
`tickvals`.
The 'ticktext' property is an array that may be specified as a tuple,
list, numpy array, or pandas Series | def ticktext(self):
"""
Sets the text displayed at the ticks position via `tickvals`.
Only has an effect if `tickmode` is set to "array". Used with
`tickvals`.
The 'ticktext' property is an array that may be specified as a tuple,
list, numpy array, or pandas Series
Returns
-------
numpy.ndarray
"""
return self["ticktext"] | [
"def",
"ticktext",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"ticktext\"",
"]"
] | [
943,
4
] | [
956,
31
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.ticktextsrc | (self) |
Sets the source reference on Chart Studio Cloud for ticktext .
The 'ticktextsrc' property must be specified as a string or
as a plotly.grid_objs.Column object
Returns
-------
str
|
Sets the source reference on Chart Studio Cloud for ticktext .
The 'ticktextsrc' property must be specified as a string or
as a plotly.grid_objs.Column object | def ticktextsrc(self):
"""
Sets the source reference on Chart Studio Cloud for ticktext .
The 'ticktextsrc' property must be specified as a string or
as a plotly.grid_objs.Column object
Returns
-------
str
"""
return self["ticktextsrc"] | [
"def",
"ticktextsrc",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"ticktextsrc\"",
"]"
] | [
965,
4
] | [
976,
34
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.tickvals | (self) |
Sets the values at which ticks on this axis appear. Only has an
effect if `tickmode` is set to "array". Used with `ticktext`.
The 'tickvals' property is an array that may be specified as a tuple,
list, numpy array, or pandas Series
Returns
-------
numpy.ndarray
|
Sets the values at which ticks on this axis appear. Only has an
effect if `tickmode` is set to "array". Used with `ticktext`.
The 'tickvals' property is an array that may be specified as a tuple,
list, numpy array, or pandas Series | def tickvals(self):
"""
Sets the values at which ticks on this axis appear. Only has an
effect if `tickmode` is set to "array". Used with `ticktext`.
The 'tickvals' property is an array that may be specified as a tuple,
list, numpy array, or pandas Series
Returns
-------
numpy.ndarray
"""
return self["tickvals"] | [
"def",
"tickvals",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"tickvals\"",
"]"
] | [
985,
4
] | [
997,
31
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.tickvalssrc | (self) |
Sets the source reference on Chart Studio Cloud for tickvals .
The 'tickvalssrc' property must be specified as a string or
as a plotly.grid_objs.Column object
Returns
-------
str
|
Sets the source reference on Chart Studio Cloud for tickvals .
The 'tickvalssrc' property must be specified as a string or
as a plotly.grid_objs.Column object | def tickvalssrc(self):
"""
Sets the source reference on Chart Studio Cloud for tickvals .
The 'tickvalssrc' property must be specified as a string or
as a plotly.grid_objs.Column object
Returns
-------
str
"""
return self["tickvalssrc"] | [
"def",
"tickvalssrc",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"tickvalssrc\"",
"]"
] | [
1006,
4
] | [
1017,
34
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.tickwidth | (self) |
Sets the tick width (in px).
The 'tickwidth' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
|
Sets the tick width (in px).
The 'tickwidth' property is a number and may be specified as:
- An int or float in the interval [0, inf] | def tickwidth(self):
"""
Sets the tick width (in px).
The 'tickwidth' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
"""
return self["tickwidth"] | [
"def",
"tickwidth",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"tickwidth\"",
"]"
] | [
1026,
4
] | [
1037,
32
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.title | (self) |
The 'title' property is an instance of Title
that may be specified as:
- An instance of :class:`plotly.graph_objs.mesh3d.colorbar.Title`
- A dict of string/value properties that will be passed
to the Title constructor
Supported dict properties:
font
Sets this color bar's title font. Note that the
title's font used to be set by the now
deprecated `titlefont` attribute.
side
Determines the location of color bar's title
with respect to the color bar. Note that the
title's location used to be set by the now
deprecated `titleside` attribute.
text
Sets the title of the color bar. Note that
before the existence of `title.text`, the
title's contents used to be defined as the
`title` attribute itself. This behavior has
been deprecated.
Returns
-------
plotly.graph_objs.mesh3d.colorbar.Title
|
The 'title' property is an instance of Title
that may be specified as:
- An instance of :class:`plotly.graph_objs.mesh3d.colorbar.Title`
- A dict of string/value properties that will be passed
to the Title constructor
Supported dict properties:
font
Sets this color bar's title font. Note that the
title's font used to be set by the now
deprecated `titlefont` attribute.
side
Determines the location of color bar's title
with respect to the color bar. Note that the
title's location used to be set by the now
deprecated `titleside` attribute.
text
Sets the title of the color bar. Note that
before the existence of `title.text`, the
title's contents used to be defined as the
`title` attribute itself. This behavior has
been deprecated. | def title(self):
"""
The 'title' property is an instance of Title
that may be specified as:
- An instance of :class:`plotly.graph_objs.mesh3d.colorbar.Title`
- A dict of string/value properties that will be passed
to the Title constructor
Supported dict properties:
font
Sets this color bar's title font. Note that the
title's font used to be set by the now
deprecated `titlefont` attribute.
side
Determines the location of color bar's title
with respect to the color bar. Note that the
title's location used to be set by the now
deprecated `titleside` attribute.
text
Sets the title of the color bar. Note that
before the existence of `title.text`, the
title's contents used to be defined as the
`title` attribute itself. This behavior has
been deprecated.
Returns
-------
plotly.graph_objs.mesh3d.colorbar.Title
"""
return self["title"] | [
"def",
"title",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"title\"",
"]"
] | [
1046,
4
] | [
1076,
28
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.titlefont | (self) |
Deprecated: Please use mesh3d.colorbar.title.font instead. Sets
this color bar's title font. Note that the title's font used to
be set by the now deprecated `titlefont` attribute.
The 'font' property is an instance of Font
that may be specified as:
- An instance of :class:`plotly.graph_objs.mesh3d.colorbar.title.Font`
- A dict of string/value properties that will be passed
to the Font constructor
Supported dict properties:
color
family
HTML font family - the typeface that will be
applied by the web browser. The web browser
will only be able to apply a font if it is
available on the system which it operates.
Provide multiple font families, separated by
commas, to indicate the preference in which to
apply fonts if they aren't available on the
system. The Chart Studio Cloud (at
https://chart-studio.plotly.com or on-premise)
generates images on a server, where only a
select number of fonts are installed and
supported. These include "Arial", "Balto",
"Courier New", "Droid Sans",, "Droid Serif",
"Droid Sans Mono", "Gravitas One", "Old
Standard TT", "Open Sans", "Overpass", "PT Sans
Narrow", "Raleway", "Times New Roman".
size
Returns
-------
|
Deprecated: Please use mesh3d.colorbar.title.font instead. Sets
this color bar's title font. Note that the title's font used to
be set by the now deprecated `titlefont` attribute.
The 'font' property is an instance of Font
that may be specified as:
- An instance of :class:`plotly.graph_objs.mesh3d.colorbar.title.Font`
- A dict of string/value properties that will be passed
to the Font constructor
Supported dict properties:
color
family
HTML font family - the typeface that will be
applied by the web browser. The web browser
will only be able to apply a font if it is
available on the system which it operates.
Provide multiple font families, separated by
commas, to indicate the preference in which to
apply fonts if they aren't available on the
system. The Chart Studio Cloud (at
https://chart-studio.plotly.com or on-premise)
generates images on a server, where only a
select number of fonts are installed and
supported. These include "Arial", "Balto",
"Courier New", "Droid Sans",, "Droid Serif",
"Droid Sans Mono", "Gravitas One", "Old
Standard TT", "Open Sans", "Overpass", "PT Sans
Narrow", "Raleway", "Times New Roman".
size | def titlefont(self):
"""
Deprecated: Please use mesh3d.colorbar.title.font instead. Sets
this color bar's title font. Note that the title's font used to
be set by the now deprecated `titlefont` attribute.
The 'font' property is an instance of Font
that may be specified as:
- An instance of :class:`plotly.graph_objs.mesh3d.colorbar.title.Font`
- A dict of string/value properties that will be passed
to the Font constructor
Supported dict properties:
color
family
HTML font family - the typeface that will be
applied by the web browser. The web browser
will only be able to apply a font if it is
available on the system which it operates.
Provide multiple font families, separated by
commas, to indicate the preference in which to
apply fonts if they aren't available on the
system. The Chart Studio Cloud (at
https://chart-studio.plotly.com or on-premise)
generates images on a server, where only a
select number of fonts are installed and
supported. These include "Arial", "Balto",
"Courier New", "Droid Sans",, "Droid Serif",
"Droid Sans Mono", "Gravitas One", "Old
Standard TT", "Open Sans", "Overpass", "PT Sans
Narrow", "Raleway", "Times New Roman".
size
Returns
-------
"""
return self["titlefont"] | [
"def",
"titlefont",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"titlefont\"",
"]"
] | [
1085,
4
] | [
1124,
32
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.titleside | (self) |
Deprecated: Please use mesh3d.colorbar.title.side instead.
Determines the location of color bar's title with respect to
the color bar. Note that the title's location used to be set by
the now deprecated `titleside` attribute.
The 'side' property is an enumeration that may be specified as:
- One of the following enumeration values:
['right', 'top', 'bottom']
Returns
-------
|
Deprecated: Please use mesh3d.colorbar.title.side instead.
Determines the location of color bar's title with respect to
the color bar. Note that the title's location used to be set by
the now deprecated `titleside` attribute.
The 'side' property is an enumeration that may be specified as:
- One of the following enumeration values:
['right', 'top', 'bottom'] | def titleside(self):
"""
Deprecated: Please use mesh3d.colorbar.title.side instead.
Determines the location of color bar's title with respect to
the color bar. Note that the title's location used to be set by
the now deprecated `titleside` attribute.
The 'side' property is an enumeration that may be specified as:
- One of the following enumeration values:
['right', 'top', 'bottom']
Returns
-------
"""
return self["titleside"] | [
"def",
"titleside",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"titleside\"",
"]"
] | [
1133,
4
] | [
1148,
32
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.x | (self) |
Sets the x position of the color bar (in plot fraction).
The 'x' property is a number and may be specified as:
- An int or float in the interval [-2, 3]
Returns
-------
int|float
|
Sets the x position of the color bar (in plot fraction).
The 'x' property is a number and may be specified as:
- An int or float in the interval [-2, 3] | def x(self):
"""
Sets the x position of the color bar (in plot fraction).
The 'x' property is a number and may be specified as:
- An int or float in the interval [-2, 3]
Returns
-------
int|float
"""
return self["x"] | [
"def",
"x",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"x\"",
"]"
] | [
1157,
4
] | [
1168,
24
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.xanchor | (self) |
Sets this color bar's horizontal position anchor. This anchor
binds the `x` position to the "left", "center" or "right" of
the color bar.
The 'xanchor' property is an enumeration that may be specified as:
- One of the following enumeration values:
['left', 'center', 'right']
Returns
-------
Any
|
Sets this color bar's horizontal position anchor. This anchor
binds the `x` position to the "left", "center" or "right" of
the color bar.
The 'xanchor' property is an enumeration that may be specified as:
- One of the following enumeration values:
['left', 'center', 'right'] | def xanchor(self):
"""
Sets this color bar's horizontal position anchor. This anchor
binds the `x` position to the "left", "center" or "right" of
the color bar.
The 'xanchor' property is an enumeration that may be specified as:
- One of the following enumeration values:
['left', 'center', 'right']
Returns
-------
Any
"""
return self["xanchor"] | [
"def",
"xanchor",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"xanchor\"",
"]"
] | [
1177,
4
] | [
1191,
30
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.xpad | (self) |
Sets the amount of padding (in px) along the x direction.
The 'xpad' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
|
Sets the amount of padding (in px) along the x direction.
The 'xpad' property is a number and may be specified as:
- An int or float in the interval [0, inf] | def xpad(self):
"""
Sets the amount of padding (in px) along the x direction.
The 'xpad' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
"""
return self["xpad"] | [
"def",
"xpad",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"xpad\"",
"]"
] | [
1200,
4
] | [
1211,
27
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.y | (self) |
Sets the y position of the color bar (in plot fraction).
The 'y' property is a number and may be specified as:
- An int or float in the interval [-2, 3]
Returns
-------
int|float
|
Sets the y position of the color bar (in plot fraction).
The 'y' property is a number and may be specified as:
- An int or float in the interval [-2, 3] | def y(self):
"""
Sets the y position of the color bar (in plot fraction).
The 'y' property is a number and may be specified as:
- An int or float in the interval [-2, 3]
Returns
-------
int|float
"""
return self["y"] | [
"def",
"y",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"y\"",
"]"
] | [
1220,
4
] | [
1231,
24
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.yanchor | (self) |
Sets this color bar's vertical position anchor This anchor
binds the `y` position to the "top", "middle" or "bottom" of
the color bar.
The 'yanchor' property is an enumeration that may be specified as:
- One of the following enumeration values:
['top', 'middle', 'bottom']
Returns
-------
Any
|
Sets this color bar's vertical position anchor This anchor
binds the `y` position to the "top", "middle" or "bottom" of
the color bar.
The 'yanchor' property is an enumeration that may be specified as:
- One of the following enumeration values:
['top', 'middle', 'bottom'] | def yanchor(self):
"""
Sets this color bar's vertical position anchor This anchor
binds the `y` position to the "top", "middle" or "bottom" of
the color bar.
The 'yanchor' property is an enumeration that may be specified as:
- One of the following enumeration values:
['top', 'middle', 'bottom']
Returns
-------
Any
"""
return self["yanchor"] | [
"def",
"yanchor",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"yanchor\"",
"]"
] | [
1240,
4
] | [
1254,
30
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.ypad | (self) |
Sets the amount of padding (in px) along the y direction.
The 'ypad' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
|
Sets the amount of padding (in px) along the y direction.
The 'ypad' property is a number and may be specified as:
- An int or float in the interval [0, inf] | def ypad(self):
"""
Sets the amount of padding (in px) along the y direction.
The 'ypad' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
"""
return self["ypad"] | [
"def",
"ypad",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"ypad\"",
"]"
] | [
1263,
4
] | [
1274,
27
] | python | en | ['en', 'error', 'th'] | False |
ColorBar.__init__ | (
self,
arg=None,
bgcolor=None,
bordercolor=None,
borderwidth=None,
dtick=None,
exponentformat=None,
len=None,
lenmode=None,
nticks=None,
outlinecolor=None,
outlinewidth=None,
separatethousands=None,
showexponent=None,
showticklabels=None,
showtickprefix=None,
showticksuffix=None,
thickness=None,
thicknessmode=None,
tick0=None,
tickangle=None,
tickcolor=None,
tickfont=None,
tickformat=None,
tickformatstops=None,
tickformatstopdefaults=None,
ticklen=None,
tickmode=None,
tickprefix=None,
ticks=None,
ticksuffix=None,
ticktext=None,
ticktextsrc=None,
tickvals=None,
tickvalssrc=None,
tickwidth=None,
title=None,
titlefont=None,
titleside=None,
x=None,
xanchor=None,
xpad=None,
y=None,
yanchor=None,
ypad=None,
**kwargs
) |
Construct a new ColorBar object
Parameters
----------
arg
dict of properties compatible with this constructor or
an instance of
:class:`plotly.graph_objs.mesh3d.ColorBar`
bgcolor
Sets the color of padded area.
bordercolor
Sets the axis line color.
borderwidth
Sets the width (in px) or the border enclosing this
color bar.
dtick
Sets the step in-between ticks on this axis. Use with
`tick0`. Must be a positive number, or special strings
available to "log" and "date" axes. If the axis `type`
is "log", then ticks are set every 10^(n*dtick) where n
is the tick number. For example, to set a tick mark at
1, 10, 100, 1000, ... set dtick to 1. To set tick marks
at 1, 100, 10000, ... set dtick to 2. To set tick marks
at 1, 5, 25, 125, 625, 3125, ... set dtick to
log_10(5), or 0.69897000433. "log" has several special
values; "L<f>", where `f` is a positive number, gives
ticks linearly spaced in value (but not position). For
example `tick0` = 0.1, `dtick` = "L0.5" will put ticks
at 0.1, 0.6, 1.1, 1.6 etc. To show powers of 10 plus
small digits between, use "D1" (all digits) or "D2"
(only 2 and 5). `tick0` is ignored for "D1" and "D2".
If the axis `type` is "date", then you must convert the
time to milliseconds. For example, to set the interval
between ticks to one day, set `dtick` to 86400000.0.
"date" also has special values "M<n>" gives ticks
spaced by a number of months. `n` must be a positive
integer. To set ticks on the 15th of every third month,
set `tick0` to "2000-01-15" and `dtick` to "M3". To set
ticks every 4 years, set `dtick` to "M48"
exponentformat
Determines a formatting rule for the tick exponents.
For example, consider the number 1,000,000,000. If
"none", it appears as 1,000,000,000. If "e", 1e+9. If
"E", 1E+9. If "power", 1x10^9 (with 9 in a super
script). If "SI", 1G. If "B", 1B.
len
Sets the length of the color bar This measure excludes
the padding of both ends. That is, the color bar length
is this length minus the padding on both ends.
lenmode
Determines whether this color bar's length (i.e. the
measure in the color variation direction) is set in
units of plot "fraction" or in *pixels. Use `len` to
set the value.
nticks
Specifies the maximum number of ticks for the
particular axis. The actual number of ticks will be
chosen automatically to be less than or equal to
`nticks`. Has an effect only if `tickmode` is set to
"auto".
outlinecolor
Sets the axis line color.
outlinewidth
Sets the width (in px) of the axis line.
separatethousands
If "true", even 4-digit integers are separated
showexponent
If "all", all exponents are shown besides their
significands. If "first", only the exponent of the
first tick is shown. If "last", only the exponent of
the last tick is shown. If "none", no exponents appear.
showticklabels
Determines whether or not the tick labels are drawn.
showtickprefix
If "all", all tick labels are displayed with a prefix.
If "first", only the first tick is displayed with a
prefix. If "last", only the last tick is displayed with
a suffix. If "none", tick prefixes are hidden.
showticksuffix
Same as `showtickprefix` but for tick suffixes.
thickness
Sets the thickness of the color bar This measure
excludes the size of the padding, ticks and labels.
thicknessmode
Determines whether this color bar's thickness (i.e. the
measure in the constant color direction) is set in
units of plot "fraction" or in "pixels". Use
`thickness` to set the value.
tick0
Sets the placement of the first tick on this axis. Use
with `dtick`. If the axis `type` is "log", then you
must take the log of your starting tick (e.g. to set
the starting tick to 100, set the `tick0` to 2) except
when `dtick`=*L<f>* (see `dtick` for more info). If the
axis `type` is "date", it should be a date string, like
date data. If the axis `type` is "category", it should
be a number, using the scale where each category is
assigned a serial number from zero in the order it
appears.
tickangle
Sets the angle of the tick labels with respect to the
horizontal. For example, a `tickangle` of -90 draws the
tick labels vertically.
tickcolor
Sets the tick color.
tickfont
Sets the color bar's tick label font
tickformat
Sets the tick label formatting rule using d3 formatting
mini-languages which are very similar to those in
Python. For numbers, see:
https://github.com/d3/d3-3.x-api-
reference/blob/master/Formatting.md#d3_format And for
dates see: https://github.com/d3/d3-3.x-api-
reference/blob/master/Time-Formatting.md#format We add
one item to d3's date formatter: "%{n}f" for fractional
seconds with n digits. For example, *2016-10-13
09:15:23.456* with tickformat "%H~%M~%S.%2f" would
display "09~15~23.46"
tickformatstops
A tuple of :class:`plotly.graph_objects.mesh3d.colorbar
.Tickformatstop` instances or dicts with compatible
properties
tickformatstopdefaults
When used in a template (as layout.template.data.mesh3d
.colorbar.tickformatstopdefaults), sets the default
property values to use for elements of
mesh3d.colorbar.tickformatstops
ticklen
Sets the tick length (in px).
tickmode
Sets the tick mode for this axis. If "auto", the number
of ticks is set via `nticks`. If "linear", the
placement of the ticks is determined by a starting
position `tick0` and a tick step `dtick` ("linear" is
the default value if `tick0` and `dtick` are provided).
If "array", the placement of the ticks is set via
`tickvals` and the tick text is `ticktext`. ("array" is
the default value if `tickvals` is provided).
tickprefix
Sets a tick label prefix.
ticks
Determines whether ticks are drawn or not. If "", this
axis' ticks are not drawn. If "outside" ("inside"),
this axis' are drawn outside (inside) the axis lines.
ticksuffix
Sets a tick label suffix.
ticktext
Sets the text displayed at the ticks position via
`tickvals`. Only has an effect if `tickmode` is set to
"array". Used with `tickvals`.
ticktextsrc
Sets the source reference on Chart Studio Cloud for
ticktext .
tickvals
Sets the values at which ticks on this axis appear.
Only has an effect if `tickmode` is set to "array".
Used with `ticktext`.
tickvalssrc
Sets the source reference on Chart Studio Cloud for
tickvals .
tickwidth
Sets the tick width (in px).
title
:class:`plotly.graph_objects.mesh3d.colorbar.Title`
instance or dict with compatible properties
titlefont
Deprecated: Please use mesh3d.colorbar.title.font
instead. Sets this color bar's title font. Note that
the title's font used to be set by the now deprecated
`titlefont` attribute.
titleside
Deprecated: Please use mesh3d.colorbar.title.side
instead. Determines the location of color bar's title
with respect to the color bar. Note that the title's
location used to be set by the now deprecated
`titleside` attribute.
x
Sets the x position of the color bar (in plot
fraction).
xanchor
Sets this color bar's horizontal position anchor. This
anchor binds the `x` position to the "left", "center"
or "right" of the color bar.
xpad
Sets the amount of padding (in px) along the x
direction.
y
Sets the y position of the color bar (in plot
fraction).
yanchor
Sets this color bar's vertical position anchor This
anchor binds the `y` position to the "top", "middle" or
"bottom" of the color bar.
ypad
Sets the amount of padding (in px) along the y
direction.
Returns
-------
ColorBar
|
Construct a new ColorBar object
Parameters
----------
arg
dict of properties compatible with this constructor or
an instance of
:class:`plotly.graph_objs.mesh3d.ColorBar`
bgcolor
Sets the color of padded area.
bordercolor
Sets the axis line color.
borderwidth
Sets the width (in px) or the border enclosing this
color bar.
dtick
Sets the step in-between ticks on this axis. Use with
`tick0`. Must be a positive number, or special strings
available to "log" and "date" axes. If the axis `type`
is "log", then ticks are set every 10^(n*dtick) where n
is the tick number. For example, to set a tick mark at
1, 10, 100, 1000, ... set dtick to 1. To set tick marks
at 1, 100, 10000, ... set dtick to 2. To set tick marks
at 1, 5, 25, 125, 625, 3125, ... set dtick to
log_10(5), or 0.69897000433. "log" has several special
values; "L<f>", where `f` is a positive number, gives
ticks linearly spaced in value (but not position). For
example `tick0` = 0.1, `dtick` = "L0.5" will put ticks
at 0.1, 0.6, 1.1, 1.6 etc. To show powers of 10 plus
small digits between, use "D1" (all digits) or "D2"
(only 2 and 5). `tick0` is ignored for "D1" and "D2".
If the axis `type` is "date", then you must convert the
time to milliseconds. For example, to set the interval
between ticks to one day, set `dtick` to 86400000.0.
"date" also has special values "M<n>" gives ticks
spaced by a number of months. `n` must be a positive
integer. To set ticks on the 15th of every third month,
set `tick0` to "2000-01-15" and `dtick` to "M3". To set
ticks every 4 years, set `dtick` to "M48"
exponentformat
Determines a formatting rule for the tick exponents.
For example, consider the number 1,000,000,000. If
"none", it appears as 1,000,000,000. If "e", 1e+9. If
"E", 1E+9. If "power", 1x10^9 (with 9 in a super
script). If "SI", 1G. If "B", 1B.
len
Sets the length of the color bar This measure excludes
the padding of both ends. That is, the color bar length
is this length minus the padding on both ends.
lenmode
Determines whether this color bar's length (i.e. the
measure in the color variation direction) is set in
units of plot "fraction" or in *pixels. Use `len` to
set the value.
nticks
Specifies the maximum number of ticks for the
particular axis. The actual number of ticks will be
chosen automatically to be less than or equal to
`nticks`. Has an effect only if `tickmode` is set to
"auto".
outlinecolor
Sets the axis line color.
outlinewidth
Sets the width (in px) of the axis line.
separatethousands
If "true", even 4-digit integers are separated
showexponent
If "all", all exponents are shown besides their
significands. If "first", only the exponent of the
first tick is shown. If "last", only the exponent of
the last tick is shown. If "none", no exponents appear.
showticklabels
Determines whether or not the tick labels are drawn.
showtickprefix
If "all", all tick labels are displayed with a prefix.
If "first", only the first tick is displayed with a
prefix. If "last", only the last tick is displayed with
a suffix. If "none", tick prefixes are hidden.
showticksuffix
Same as `showtickprefix` but for tick suffixes.
thickness
Sets the thickness of the color bar This measure
excludes the size of the padding, ticks and labels.
thicknessmode
Determines whether this color bar's thickness (i.e. the
measure in the constant color direction) is set in
units of plot "fraction" or in "pixels". Use
`thickness` to set the value.
tick0
Sets the placement of the first tick on this axis. Use
with `dtick`. If the axis `type` is "log", then you
must take the log of your starting tick (e.g. to set
the starting tick to 100, set the `tick0` to 2) except
when `dtick`=*L<f>* (see `dtick` for more info). If the
axis `type` is "date", it should be a date string, like
date data. If the axis `type` is "category", it should
be a number, using the scale where each category is
assigned a serial number from zero in the order it
appears.
tickangle
Sets the angle of the tick labels with respect to the
horizontal. For example, a `tickangle` of -90 draws the
tick labels vertically.
tickcolor
Sets the tick color.
tickfont
Sets the color bar's tick label font
tickformat
Sets the tick label formatting rule using d3 formatting
mini-languages which are very similar to those in
Python. For numbers, see:
https://github.com/d3/d3-3.x-api-
reference/blob/master/Formatting.md#d3_format And for
dates see: https://github.com/d3/d3-3.x-api-
reference/blob/master/Time-Formatting.md#format We add
one item to d3's date formatter: "%{n}f" for fractional
seconds with n digits. For example, *2016-10-13
09:15:23.456* with tickformat "%H~%M~%S.%2f" would
display "09~15~23.46"
tickformatstops
A tuple of :class:`plotly.graph_objects.mesh3d.colorbar
.Tickformatstop` instances or dicts with compatible
properties
tickformatstopdefaults
When used in a template (as layout.template.data.mesh3d
.colorbar.tickformatstopdefaults), sets the default
property values to use for elements of
mesh3d.colorbar.tickformatstops
ticklen
Sets the tick length (in px).
tickmode
Sets the tick mode for this axis. If "auto", the number
of ticks is set via `nticks`. If "linear", the
placement of the ticks is determined by a starting
position `tick0` and a tick step `dtick` ("linear" is
the default value if `tick0` and `dtick` are provided).
If "array", the placement of the ticks is set via
`tickvals` and the tick text is `ticktext`. ("array" is
the default value if `tickvals` is provided).
tickprefix
Sets a tick label prefix.
ticks
Determines whether ticks are drawn or not. If "", this
axis' ticks are not drawn. If "outside" ("inside"),
this axis' are drawn outside (inside) the axis lines.
ticksuffix
Sets a tick label suffix.
ticktext
Sets the text displayed at the ticks position via
`tickvals`. Only has an effect if `tickmode` is set to
"array". Used with `tickvals`.
ticktextsrc
Sets the source reference on Chart Studio Cloud for
ticktext .
tickvals
Sets the values at which ticks on this axis appear.
Only has an effect if `tickmode` is set to "array".
Used with `ticktext`.
tickvalssrc
Sets the source reference on Chart Studio Cloud for
tickvals .
tickwidth
Sets the tick width (in px).
title
:class:`plotly.graph_objects.mesh3d.colorbar.Title`
instance or dict with compatible properties
titlefont
Deprecated: Please use mesh3d.colorbar.title.font
instead. Sets this color bar's title font. Note that
the title's font used to be set by the now deprecated
`titlefont` attribute.
titleside
Deprecated: Please use mesh3d.colorbar.title.side
instead. Determines the location of color bar's title
with respect to the color bar. Note that the title's
location used to be set by the now deprecated
`titleside` attribute.
x
Sets the x position of the color bar (in plot
fraction).
xanchor
Sets this color bar's horizontal position anchor. This
anchor binds the `x` position to the "left", "center"
or "right" of the color bar.
xpad
Sets the amount of padding (in px) along the x
direction.
y
Sets the y position of the color bar (in plot
fraction).
yanchor
Sets this color bar's vertical position anchor This
anchor binds the `y` position to the "top", "middle" or
"bottom" of the color bar.
ypad
Sets the amount of padding (in px) along the y
direction. | def __init__(
self,
arg=None,
bgcolor=None,
bordercolor=None,
borderwidth=None,
dtick=None,
exponentformat=None,
len=None,
lenmode=None,
nticks=None,
outlinecolor=None,
outlinewidth=None,
separatethousands=None,
showexponent=None,
showticklabels=None,
showtickprefix=None,
showticksuffix=None,
thickness=None,
thicknessmode=None,
tick0=None,
tickangle=None,
tickcolor=None,
tickfont=None,
tickformat=None,
tickformatstops=None,
tickformatstopdefaults=None,
ticklen=None,
tickmode=None,
tickprefix=None,
ticks=None,
ticksuffix=None,
ticktext=None,
ticktextsrc=None,
tickvals=None,
tickvalssrc=None,
tickwidth=None,
title=None,
titlefont=None,
titleside=None,
x=None,
xanchor=None,
xpad=None,
y=None,
yanchor=None,
ypad=None,
**kwargs
):
"""
Construct a new ColorBar object
Parameters
----------
arg
dict of properties compatible with this constructor or
an instance of
:class:`plotly.graph_objs.mesh3d.ColorBar`
bgcolor
Sets the color of padded area.
bordercolor
Sets the axis line color.
borderwidth
Sets the width (in px) or the border enclosing this
color bar.
dtick
Sets the step in-between ticks on this axis. Use with
`tick0`. Must be a positive number, or special strings
available to "log" and "date" axes. If the axis `type`
is "log", then ticks are set every 10^(n*dtick) where n
is the tick number. For example, to set a tick mark at
1, 10, 100, 1000, ... set dtick to 1. To set tick marks
at 1, 100, 10000, ... set dtick to 2. To set tick marks
at 1, 5, 25, 125, 625, 3125, ... set dtick to
log_10(5), or 0.69897000433. "log" has several special
values; "L<f>", where `f` is a positive number, gives
ticks linearly spaced in value (but not position). For
example `tick0` = 0.1, `dtick` = "L0.5" will put ticks
at 0.1, 0.6, 1.1, 1.6 etc. To show powers of 10 plus
small digits between, use "D1" (all digits) or "D2"
(only 2 and 5). `tick0` is ignored for "D1" and "D2".
If the axis `type` is "date", then you must convert the
time to milliseconds. For example, to set the interval
between ticks to one day, set `dtick` to 86400000.0.
"date" also has special values "M<n>" gives ticks
spaced by a number of months. `n` must be a positive
integer. To set ticks on the 15th of every third month,
set `tick0` to "2000-01-15" and `dtick` to "M3". To set
ticks every 4 years, set `dtick` to "M48"
exponentformat
Determines a formatting rule for the tick exponents.
For example, consider the number 1,000,000,000. If
"none", it appears as 1,000,000,000. If "e", 1e+9. If
"E", 1E+9. If "power", 1x10^9 (with 9 in a super
script). If "SI", 1G. If "B", 1B.
len
Sets the length of the color bar This measure excludes
the padding of both ends. That is, the color bar length
is this length minus the padding on both ends.
lenmode
Determines whether this color bar's length (i.e. the
measure in the color variation direction) is set in
units of plot "fraction" or in *pixels. Use `len` to
set the value.
nticks
Specifies the maximum number of ticks for the
particular axis. The actual number of ticks will be
chosen automatically to be less than or equal to
`nticks`. Has an effect only if `tickmode` is set to
"auto".
outlinecolor
Sets the axis line color.
outlinewidth
Sets the width (in px) of the axis line.
separatethousands
If "true", even 4-digit integers are separated
showexponent
If "all", all exponents are shown besides their
significands. If "first", only the exponent of the
first tick is shown. If "last", only the exponent of
the last tick is shown. If "none", no exponents appear.
showticklabels
Determines whether or not the tick labels are drawn.
showtickprefix
If "all", all tick labels are displayed with a prefix.
If "first", only the first tick is displayed with a
prefix. If "last", only the last tick is displayed with
a suffix. If "none", tick prefixes are hidden.
showticksuffix
Same as `showtickprefix` but for tick suffixes.
thickness
Sets the thickness of the color bar This measure
excludes the size of the padding, ticks and labels.
thicknessmode
Determines whether this color bar's thickness (i.e. the
measure in the constant color direction) is set in
units of plot "fraction" or in "pixels". Use
`thickness` to set the value.
tick0
Sets the placement of the first tick on this axis. Use
with `dtick`. If the axis `type` is "log", then you
must take the log of your starting tick (e.g. to set
the starting tick to 100, set the `tick0` to 2) except
when `dtick`=*L<f>* (see `dtick` for more info). If the
axis `type` is "date", it should be a date string, like
date data. If the axis `type` is "category", it should
be a number, using the scale where each category is
assigned a serial number from zero in the order it
appears.
tickangle
Sets the angle of the tick labels with respect to the
horizontal. For example, a `tickangle` of -90 draws the
tick labels vertically.
tickcolor
Sets the tick color.
tickfont
Sets the color bar's tick label font
tickformat
Sets the tick label formatting rule using d3 formatting
mini-languages which are very similar to those in
Python. For numbers, see:
https://github.com/d3/d3-3.x-api-
reference/blob/master/Formatting.md#d3_format And for
dates see: https://github.com/d3/d3-3.x-api-
reference/blob/master/Time-Formatting.md#format We add
one item to d3's date formatter: "%{n}f" for fractional
seconds with n digits. For example, *2016-10-13
09:15:23.456* with tickformat "%H~%M~%S.%2f" would
display "09~15~23.46"
tickformatstops
A tuple of :class:`plotly.graph_objects.mesh3d.colorbar
.Tickformatstop` instances or dicts with compatible
properties
tickformatstopdefaults
When used in a template (as layout.template.data.mesh3d
.colorbar.tickformatstopdefaults), sets the default
property values to use for elements of
mesh3d.colorbar.tickformatstops
ticklen
Sets the tick length (in px).
tickmode
Sets the tick mode for this axis. If "auto", the number
of ticks is set via `nticks`. If "linear", the
placement of the ticks is determined by a starting
position `tick0` and a tick step `dtick` ("linear" is
the default value if `tick0` and `dtick` are provided).
If "array", the placement of the ticks is set via
`tickvals` and the tick text is `ticktext`. ("array" is
the default value if `tickvals` is provided).
tickprefix
Sets a tick label prefix.
ticks
Determines whether ticks are drawn or not. If "", this
axis' ticks are not drawn. If "outside" ("inside"),
this axis' are drawn outside (inside) the axis lines.
ticksuffix
Sets a tick label suffix.
ticktext
Sets the text displayed at the ticks position via
`tickvals`. Only has an effect if `tickmode` is set to
"array". Used with `tickvals`.
ticktextsrc
Sets the source reference on Chart Studio Cloud for
ticktext .
tickvals
Sets the values at which ticks on this axis appear.
Only has an effect if `tickmode` is set to "array".
Used with `ticktext`.
tickvalssrc
Sets the source reference on Chart Studio Cloud for
tickvals .
tickwidth
Sets the tick width (in px).
title
:class:`plotly.graph_objects.mesh3d.colorbar.Title`
instance or dict with compatible properties
titlefont
Deprecated: Please use mesh3d.colorbar.title.font
instead. Sets this color bar's title font. Note that
the title's font used to be set by the now deprecated
`titlefont` attribute.
titleside
Deprecated: Please use mesh3d.colorbar.title.side
instead. Determines the location of color bar's title
with respect to the color bar. Note that the title's
location used to be set by the now deprecated
`titleside` attribute.
x
Sets the x position of the color bar (in plot
fraction).
xanchor
Sets this color bar's horizontal position anchor. This
anchor binds the `x` position to the "left", "center"
or "right" of the color bar.
xpad
Sets the amount of padding (in px) along the x
direction.
y
Sets the y position of the color bar (in plot
fraction).
yanchor
Sets this color bar's vertical position anchor This
anchor binds the `y` position to the "top", "middle" or
"bottom" of the color bar.
ypad
Sets the amount of padding (in px) along the y
direction.
Returns
-------
ColorBar
"""
super(ColorBar, self).__init__("colorbar")
if "_parent" in kwargs:
self._parent = kwargs["_parent"]
return
# Validate arg
# ------------
if arg is None:
arg = {}
elif isinstance(arg, self.__class__):
arg = arg.to_plotly_json()
elif isinstance(arg, dict):
arg = _copy.copy(arg)
else:
raise ValueError(
"""\
The first argument to the plotly.graph_objs.mesh3d.ColorBar
constructor must be a dict or
an instance of :class:`plotly.graph_objs.mesh3d.ColorBar`"""
)
# Handle skip_invalid
# -------------------
self._skip_invalid = kwargs.pop("skip_invalid", False)
self._validate = kwargs.pop("_validate", True)
# Populate data dict with properties
# ----------------------------------
_v = arg.pop("bgcolor", None)
_v = bgcolor if bgcolor is not None else _v
if _v is not None:
self["bgcolor"] = _v
_v = arg.pop("bordercolor", None)
_v = bordercolor if bordercolor is not None else _v
if _v is not None:
self["bordercolor"] = _v
_v = arg.pop("borderwidth", None)
_v = borderwidth if borderwidth is not None else _v
if _v is not None:
self["borderwidth"] = _v
_v = arg.pop("dtick", None)
_v = dtick if dtick is not None else _v
if _v is not None:
self["dtick"] = _v
_v = arg.pop("exponentformat", None)
_v = exponentformat if exponentformat is not None else _v
if _v is not None:
self["exponentformat"] = _v
_v = arg.pop("len", None)
_v = len if len is not None else _v
if _v is not None:
self["len"] = _v
_v = arg.pop("lenmode", None)
_v = lenmode if lenmode is not None else _v
if _v is not None:
self["lenmode"] = _v
_v = arg.pop("nticks", None)
_v = nticks if nticks is not None else _v
if _v is not None:
self["nticks"] = _v
_v = arg.pop("outlinecolor", None)
_v = outlinecolor if outlinecolor is not None else _v
if _v is not None:
self["outlinecolor"] = _v
_v = arg.pop("outlinewidth", None)
_v = outlinewidth if outlinewidth is not None else _v
if _v is not None:
self["outlinewidth"] = _v
_v = arg.pop("separatethousands", None)
_v = separatethousands if separatethousands is not None else _v
if _v is not None:
self["separatethousands"] = _v
_v = arg.pop("showexponent", None)
_v = showexponent if showexponent is not None else _v
if _v is not None:
self["showexponent"] = _v
_v = arg.pop("showticklabels", None)
_v = showticklabels if showticklabels is not None else _v
if _v is not None:
self["showticklabels"] = _v
_v = arg.pop("showtickprefix", None)
_v = showtickprefix if showtickprefix is not None else _v
if _v is not None:
self["showtickprefix"] = _v
_v = arg.pop("showticksuffix", None)
_v = showticksuffix if showticksuffix is not None else _v
if _v is not None:
self["showticksuffix"] = _v
_v = arg.pop("thickness", None)
_v = thickness if thickness is not None else _v
if _v is not None:
self["thickness"] = _v
_v = arg.pop("thicknessmode", None)
_v = thicknessmode if thicknessmode is not None else _v
if _v is not None:
self["thicknessmode"] = _v
_v = arg.pop("tick0", None)
_v = tick0 if tick0 is not None else _v
if _v is not None:
self["tick0"] = _v
_v = arg.pop("tickangle", None)
_v = tickangle if tickangle is not None else _v
if _v is not None:
self["tickangle"] = _v
_v = arg.pop("tickcolor", None)
_v = tickcolor if tickcolor is not None else _v
if _v is not None:
self["tickcolor"] = _v
_v = arg.pop("tickfont", None)
_v = tickfont if tickfont is not None else _v
if _v is not None:
self["tickfont"] = _v
_v = arg.pop("tickformat", None)
_v = tickformat if tickformat is not None else _v
if _v is not None:
self["tickformat"] = _v
_v = arg.pop("tickformatstops", None)
_v = tickformatstops if tickformatstops is not None else _v
if _v is not None:
self["tickformatstops"] = _v
_v = arg.pop("tickformatstopdefaults", None)
_v = tickformatstopdefaults if tickformatstopdefaults is not None else _v
if _v is not None:
self["tickformatstopdefaults"] = _v
_v = arg.pop("ticklen", None)
_v = ticklen if ticklen is not None else _v
if _v is not None:
self["ticklen"] = _v
_v = arg.pop("tickmode", None)
_v = tickmode if tickmode is not None else _v
if _v is not None:
self["tickmode"] = _v
_v = arg.pop("tickprefix", None)
_v = tickprefix if tickprefix is not None else _v
if _v is not None:
self["tickprefix"] = _v
_v = arg.pop("ticks", None)
_v = ticks if ticks is not None else _v
if _v is not None:
self["ticks"] = _v
_v = arg.pop("ticksuffix", None)
_v = ticksuffix if ticksuffix is not None else _v
if _v is not None:
self["ticksuffix"] = _v
_v = arg.pop("ticktext", None)
_v = ticktext if ticktext is not None else _v
if _v is not None:
self["ticktext"] = _v
_v = arg.pop("ticktextsrc", None)
_v = ticktextsrc if ticktextsrc is not None else _v
if _v is not None:
self["ticktextsrc"] = _v
_v = arg.pop("tickvals", None)
_v = tickvals if tickvals is not None else _v
if _v is not None:
self["tickvals"] = _v
_v = arg.pop("tickvalssrc", None)
_v = tickvalssrc if tickvalssrc is not None else _v
if _v is not None:
self["tickvalssrc"] = _v
_v = arg.pop("tickwidth", None)
_v = tickwidth if tickwidth is not None else _v
if _v is not None:
self["tickwidth"] = _v
_v = arg.pop("title", None)
_v = title if title is not None else _v
if _v is not None:
self["title"] = _v
_v = arg.pop("titlefont", None)
_v = titlefont if titlefont is not None else _v
if _v is not None:
self["titlefont"] = _v
_v = arg.pop("titleside", None)
_v = titleside if titleside is not None else _v
if _v is not None:
self["titleside"] = _v
_v = arg.pop("x", None)
_v = x if x is not None else _v
if _v is not None:
self["x"] = _v
_v = arg.pop("xanchor", None)
_v = xanchor if xanchor is not None else _v
if _v is not None:
self["xanchor"] = _v
_v = arg.pop("xpad", None)
_v = xpad if xpad is not None else _v
if _v is not None:
self["xpad"] = _v
_v = arg.pop("y", None)
_v = y if y is not None else _v
if _v is not None:
self["y"] = _v
_v = arg.pop("yanchor", None)
_v = yanchor if yanchor is not None else _v
if _v is not None:
self["yanchor"] = _v
_v = arg.pop("ypad", None)
_v = ypad if ypad is not None else _v
if _v is not None:
self["ypad"] = _v
# Process unknown kwargs
# ----------------------
self._process_kwargs(**dict(arg, **kwargs))
# Reset skip_invalid
# ------------------
self._skip_invalid = False | [
"def",
"__init__",
"(",
"self",
",",
"arg",
"=",
"None",
",",
"bgcolor",
"=",
"None",
",",
"bordercolor",
"=",
"None",
",",
"borderwidth",
"=",
"None",
",",
"dtick",
"=",
"None",
",",
"exponentformat",
"=",
"None",
",",
"len",
"=",
"None",
",",
"lenmode",
"=",
"None",
",",
"nticks",
"=",
"None",
",",
"outlinecolor",
"=",
"None",
",",
"outlinewidth",
"=",
"None",
",",
"separatethousands",
"=",
"None",
",",
"showexponent",
"=",
"None",
",",
"showticklabels",
"=",
"None",
",",
"showtickprefix",
"=",
"None",
",",
"showticksuffix",
"=",
"None",
",",
"thickness",
"=",
"None",
",",
"thicknessmode",
"=",
"None",
",",
"tick0",
"=",
"None",
",",
"tickangle",
"=",
"None",
",",
"tickcolor",
"=",
"None",
",",
"tickfont",
"=",
"None",
",",
"tickformat",
"=",
"None",
",",
"tickformatstops",
"=",
"None",
",",
"tickformatstopdefaults",
"=",
"None",
",",
"ticklen",
"=",
"None",
",",
"tickmode",
"=",
"None",
",",
"tickprefix",
"=",
"None",
",",
"ticks",
"=",
"None",
",",
"ticksuffix",
"=",
"None",
",",
"ticktext",
"=",
"None",
",",
"ticktextsrc",
"=",
"None",
",",
"tickvals",
"=",
"None",
",",
"tickvalssrc",
"=",
"None",
",",
"tickwidth",
"=",
"None",
",",
"title",
"=",
"None",
",",
"titlefont",
"=",
"None",
",",
"titleside",
"=",
"None",
",",
"x",
"=",
"None",
",",
"xanchor",
"=",
"None",
",",
"xpad",
"=",
"None",
",",
"y",
"=",
"None",
",",
"yanchor",
"=",
"None",
",",
"ypad",
"=",
"None",
",",
"*",
"*",
"kwargs",
")",
":",
"super",
"(",
"ColorBar",
",",
"self",
")",
".",
"__init__",
"(",
"\"colorbar\"",
")",
"if",
"\"_parent\"",
"in",
"kwargs",
":",
"self",
".",
"_parent",
"=",
"kwargs",
"[",
"\"_parent\"",
"]",
"return",
"# Validate arg",
"# ------------",
"if",
"arg",
"is",
"None",
":",
"arg",
"=",
"{",
"}",
"elif",
"isinstance",
"(",
"arg",
",",
"self",
".",
"__class__",
")",
":",
"arg",
"=",
"arg",
".",
"to_plotly_json",
"(",
")",
"elif",
"isinstance",
"(",
"arg",
",",
"dict",
")",
":",
"arg",
"=",
"_copy",
".",
"copy",
"(",
"arg",
")",
"else",
":",
"raise",
"ValueError",
"(",
"\"\"\"\\\nThe first argument to the plotly.graph_objs.mesh3d.ColorBar \nconstructor must be a dict or \nan instance of :class:`plotly.graph_objs.mesh3d.ColorBar`\"\"\"",
")",
"# Handle skip_invalid",
"# -------------------",
"self",
".",
"_skip_invalid",
"=",
"kwargs",
".",
"pop",
"(",
"\"skip_invalid\"",
",",
"False",
")",
"self",
".",
"_validate",
"=",
"kwargs",
".",
"pop",
"(",
"\"_validate\"",
",",
"True",
")",
"# Populate data dict with properties",
"# ----------------------------------",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"bgcolor\"",
",",
"None",
")",
"_v",
"=",
"bgcolor",
"if",
"bgcolor",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"bgcolor\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"bordercolor\"",
",",
"None",
")",
"_v",
"=",
"bordercolor",
"if",
"bordercolor",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"bordercolor\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"borderwidth\"",
",",
"None",
")",
"_v",
"=",
"borderwidth",
"if",
"borderwidth",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"borderwidth\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"dtick\"",
",",
"None",
")",
"_v",
"=",
"dtick",
"if",
"dtick",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"dtick\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"exponentformat\"",
",",
"None",
")",
"_v",
"=",
"exponentformat",
"if",
"exponentformat",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"exponentformat\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"len\"",
",",
"None",
")",
"_v",
"=",
"len",
"if",
"len",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"len\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"lenmode\"",
",",
"None",
")",
"_v",
"=",
"lenmode",
"if",
"lenmode",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"lenmode\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"nticks\"",
",",
"None",
")",
"_v",
"=",
"nticks",
"if",
"nticks",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"nticks\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"outlinecolor\"",
",",
"None",
")",
"_v",
"=",
"outlinecolor",
"if",
"outlinecolor",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"outlinecolor\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"outlinewidth\"",
",",
"None",
")",
"_v",
"=",
"outlinewidth",
"if",
"outlinewidth",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"outlinewidth\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"separatethousands\"",
",",
"None",
")",
"_v",
"=",
"separatethousands",
"if",
"separatethousands",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"separatethousands\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"showexponent\"",
",",
"None",
")",
"_v",
"=",
"showexponent",
"if",
"showexponent",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"showexponent\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"showticklabels\"",
",",
"None",
")",
"_v",
"=",
"showticklabels",
"if",
"showticklabels",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"showticklabels\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"showtickprefix\"",
",",
"None",
")",
"_v",
"=",
"showtickprefix",
"if",
"showtickprefix",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"showtickprefix\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"showticksuffix\"",
",",
"None",
")",
"_v",
"=",
"showticksuffix",
"if",
"showticksuffix",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"showticksuffix\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"thickness\"",
",",
"None",
")",
"_v",
"=",
"thickness",
"if",
"thickness",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"thickness\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"thicknessmode\"",
",",
"None",
")",
"_v",
"=",
"thicknessmode",
"if",
"thicknessmode",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"thicknessmode\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"tick0\"",
",",
"None",
")",
"_v",
"=",
"tick0",
"if",
"tick0",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"tick0\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"tickangle\"",
",",
"None",
")",
"_v",
"=",
"tickangle",
"if",
"tickangle",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"tickangle\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"tickcolor\"",
",",
"None",
")",
"_v",
"=",
"tickcolor",
"if",
"tickcolor",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"tickcolor\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"tickfont\"",
",",
"None",
")",
"_v",
"=",
"tickfont",
"if",
"tickfont",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"tickfont\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"tickformat\"",
",",
"None",
")",
"_v",
"=",
"tickformat",
"if",
"tickformat",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"tickformat\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"tickformatstops\"",
",",
"None",
")",
"_v",
"=",
"tickformatstops",
"if",
"tickformatstops",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"tickformatstops\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"tickformatstopdefaults\"",
",",
"None",
")",
"_v",
"=",
"tickformatstopdefaults",
"if",
"tickformatstopdefaults",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"tickformatstopdefaults\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"ticklen\"",
",",
"None",
")",
"_v",
"=",
"ticklen",
"if",
"ticklen",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"ticklen\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"tickmode\"",
",",
"None",
")",
"_v",
"=",
"tickmode",
"if",
"tickmode",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"tickmode\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"tickprefix\"",
",",
"None",
")",
"_v",
"=",
"tickprefix",
"if",
"tickprefix",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"tickprefix\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"ticks\"",
",",
"None",
")",
"_v",
"=",
"ticks",
"if",
"ticks",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"ticks\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"ticksuffix\"",
",",
"None",
")",
"_v",
"=",
"ticksuffix",
"if",
"ticksuffix",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"ticksuffix\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"ticktext\"",
",",
"None",
")",
"_v",
"=",
"ticktext",
"if",
"ticktext",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"ticktext\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"ticktextsrc\"",
",",
"None",
")",
"_v",
"=",
"ticktextsrc",
"if",
"ticktextsrc",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"ticktextsrc\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"tickvals\"",
",",
"None",
")",
"_v",
"=",
"tickvals",
"if",
"tickvals",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"tickvals\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"tickvalssrc\"",
",",
"None",
")",
"_v",
"=",
"tickvalssrc",
"if",
"tickvalssrc",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"tickvalssrc\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"tickwidth\"",
",",
"None",
")",
"_v",
"=",
"tickwidth",
"if",
"tickwidth",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"tickwidth\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"title\"",
",",
"None",
")",
"_v",
"=",
"title",
"if",
"title",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"title\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"titlefont\"",
",",
"None",
")",
"_v",
"=",
"titlefont",
"if",
"titlefont",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"titlefont\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"titleside\"",
",",
"None",
")",
"_v",
"=",
"titleside",
"if",
"titleside",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"titleside\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"x\"",
",",
"None",
")",
"_v",
"=",
"x",
"if",
"x",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"x\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"xanchor\"",
",",
"None",
")",
"_v",
"=",
"xanchor",
"if",
"xanchor",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"xanchor\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"xpad\"",
",",
"None",
")",
"_v",
"=",
"xpad",
"if",
"xpad",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"xpad\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"y\"",
",",
"None",
")",
"_v",
"=",
"y",
"if",
"y",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"y\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"yanchor\"",
",",
"None",
")",
"_v",
"=",
"yanchor",
"if",
"yanchor",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"yanchor\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"ypad\"",
",",
"None",
")",
"_v",
"=",
"ypad",
"if",
"ypad",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"ypad\"",
"]",
"=",
"_v",
"# Process unknown kwargs",
"# ----------------------",
"self",
".",
"_process_kwargs",
"(",
"*",
"*",
"dict",
"(",
"arg",
",",
"*",
"*",
"kwargs",
")",
")",
"# Reset skip_invalid",
"# ------------------",
"self",
".",
"_skip_invalid",
"=",
"False"
] | [
1481,
4
] | [
1940,
34
] | python | en | ['en', 'error', 'th'] | False |
Title.font | (self) |
Sets this color bar's title font. Note that the title's font
used to be set by the now deprecated `titlefont` attribute.
The 'font' property is an instance of Font
that may be specified as:
- An instance of :class:`plotly.graph_objs.mesh3d.colorbar.title.Font`
- A dict of string/value properties that will be passed
to the Font constructor
Supported dict properties:
color
family
HTML font family - the typeface that will be
applied by the web browser. The web browser
will only be able to apply a font if it is
available on the system which it operates.
Provide multiple font families, separated by
commas, to indicate the preference in which to
apply fonts if they aren't available on the
system. The Chart Studio Cloud (at
https://chart-studio.plotly.com or on-premise)
generates images on a server, where only a
select number of fonts are installed and
supported. These include "Arial", "Balto",
"Courier New", "Droid Sans",, "Droid Serif",
"Droid Sans Mono", "Gravitas One", "Old
Standard TT", "Open Sans", "Overpass", "PT Sans
Narrow", "Raleway", "Times New Roman".
size
Returns
-------
plotly.graph_objs.mesh3d.colorbar.title.Font
|
Sets this color bar's title font. Note that the title's font
used to be set by the now deprecated `titlefont` attribute.
The 'font' property is an instance of Font
that may be specified as:
- An instance of :class:`plotly.graph_objs.mesh3d.colorbar.title.Font`
- A dict of string/value properties that will be passed
to the Font constructor
Supported dict properties:
color
family
HTML font family - the typeface that will be
applied by the web browser. The web browser
will only be able to apply a font if it is
available on the system which it operates.
Provide multiple font families, separated by
commas, to indicate the preference in which to
apply fonts if they aren't available on the
system. The Chart Studio Cloud (at
https://chart-studio.plotly.com or on-premise)
generates images on a server, where only a
select number of fonts are installed and
supported. These include "Arial", "Balto",
"Courier New", "Droid Sans",, "Droid Serif",
"Droid Sans Mono", "Gravitas One", "Old
Standard TT", "Open Sans", "Overpass", "PT Sans
Narrow", "Raleway", "Times New Roman".
size | def font(self):
"""
Sets this color bar's title font. Note that the title's font
used to be set by the now deprecated `titlefont` attribute.
The 'font' property is an instance of Font
that may be specified as:
- An instance of :class:`plotly.graph_objs.mesh3d.colorbar.title.Font`
- A dict of string/value properties that will be passed
to the Font constructor
Supported dict properties:
color
family
HTML font family - the typeface that will be
applied by the web browser. The web browser
will only be able to apply a font if it is
available on the system which it operates.
Provide multiple font families, separated by
commas, to indicate the preference in which to
apply fonts if they aren't available on the
system. The Chart Studio Cloud (at
https://chart-studio.plotly.com or on-premise)
generates images on a server, where only a
select number of fonts are installed and
supported. These include "Arial", "Balto",
"Courier New", "Droid Sans",, "Droid Serif",
"Droid Sans Mono", "Gravitas One", "Old
Standard TT", "Open Sans", "Overpass", "PT Sans
Narrow", "Raleway", "Times New Roman".
size
Returns
-------
plotly.graph_objs.mesh3d.colorbar.title.Font
"""
return self["font"] | [
"def",
"font",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"font\"",
"]"
] | [
15,
4
] | [
53,
27
] | python | en | ['en', 'error', 'th'] | False |
Title.side | (self) |
Determines the location of color bar's title with respect to
the color bar. Note that the title's location used to be set by
the now deprecated `titleside` attribute.
The 'side' property is an enumeration that may be specified as:
- One of the following enumeration values:
['right', 'top', 'bottom']
Returns
-------
Any
|
Determines the location of color bar's title with respect to
the color bar. Note that the title's location used to be set by
the now deprecated `titleside` attribute.
The 'side' property is an enumeration that may be specified as:
- One of the following enumeration values:
['right', 'top', 'bottom'] | def side(self):
"""
Determines the location of color bar's title with respect to
the color bar. Note that the title's location used to be set by
the now deprecated `titleside` attribute.
The 'side' property is an enumeration that may be specified as:
- One of the following enumeration values:
['right', 'top', 'bottom']
Returns
-------
Any
"""
return self["side"] | [
"def",
"side",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"side\"",
"]"
] | [
62,
4
] | [
76,
27
] | python | en | ['en', 'error', 'th'] | False |
Title.text | (self) |
Sets the title of the color bar. Note that before the existence
of `title.text`, the title's contents used to be defined as the
`title` attribute itself. This behavior has been deprecated.
The 'text' property is a string and must be specified as:
- A string
- A number that will be converted to a string
Returns
-------
str
|
Sets the title of the color bar. Note that before the existence
of `title.text`, the title's contents used to be defined as the
`title` attribute itself. This behavior has been deprecated.
The 'text' property is a string and must be specified as:
- A string
- A number that will be converted to a string | def text(self):
"""
Sets the title of the color bar. Note that before the existence
of `title.text`, the title's contents used to be defined as the
`title` attribute itself. This behavior has been deprecated.
The 'text' property is a string and must be specified as:
- A string
- A number that will be converted to a string
Returns
-------
str
"""
return self["text"] | [
"def",
"text",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"text\"",
"]"
] | [
85,
4
] | [
99,
27
] | python | en | ['en', 'error', 'th'] | False |
Title.__init__ | (self, arg=None, font=None, side=None, text=None, **kwargs) |
Construct a new Title object
Parameters
----------
arg
dict of properties compatible with this constructor or
an instance of
:class:`plotly.graph_objs.mesh3d.colorbar.Title`
font
Sets this color bar's title font. Note that the title's
font used to be set by the now deprecated `titlefont`
attribute.
side
Determines the location of color bar's title with
respect to the color bar. Note that the title's
location used to be set by the now deprecated
`titleside` attribute.
text
Sets the title of the color bar. Note that before the
existence of `title.text`, the title's contents used to
be defined as the `title` attribute itself. This
behavior has been deprecated.
Returns
-------
Title
|
Construct a new Title object
Parameters
----------
arg
dict of properties compatible with this constructor or
an instance of
:class:`plotly.graph_objs.mesh3d.colorbar.Title`
font
Sets this color bar's title font. Note that the title's
font used to be set by the now deprecated `titlefont`
attribute.
side
Determines the location of color bar's title with
respect to the color bar. Note that the title's
location used to be set by the now deprecated
`titleside` attribute.
text
Sets the title of the color bar. Note that before the
existence of `title.text`, the title's contents used to
be defined as the `title` attribute itself. This
behavior has been deprecated. | def __init__(self, arg=None, font=None, side=None, text=None, **kwargs):
"""
Construct a new Title object
Parameters
----------
arg
dict of properties compatible with this constructor or
an instance of
:class:`plotly.graph_objs.mesh3d.colorbar.Title`
font
Sets this color bar's title font. Note that the title's
font used to be set by the now deprecated `titlefont`
attribute.
side
Determines the location of color bar's title with
respect to the color bar. Note that the title's
location used to be set by the now deprecated
`titleside` attribute.
text
Sets the title of the color bar. Note that before the
existence of `title.text`, the title's contents used to
be defined as the `title` attribute itself. This
behavior has been deprecated.
Returns
-------
Title
"""
super(Title, self).__init__("title")
if "_parent" in kwargs:
self._parent = kwargs["_parent"]
return
# Validate arg
# ------------
if arg is None:
arg = {}
elif isinstance(arg, self.__class__):
arg = arg.to_plotly_json()
elif isinstance(arg, dict):
arg = _copy.copy(arg)
else:
raise ValueError(
"""\
The first argument to the plotly.graph_objs.mesh3d.colorbar.Title
constructor must be a dict or
an instance of :class:`plotly.graph_objs.mesh3d.colorbar.Title`"""
)
# Handle skip_invalid
# -------------------
self._skip_invalid = kwargs.pop("skip_invalid", False)
self._validate = kwargs.pop("_validate", True)
# Populate data dict with properties
# ----------------------------------
_v = arg.pop("font", None)
_v = font if font is not None else _v
if _v is not None:
self["font"] = _v
_v = arg.pop("side", None)
_v = side if side is not None else _v
if _v is not None:
self["side"] = _v
_v = arg.pop("text", None)
_v = text if text is not None else _v
if _v is not None:
self["text"] = _v
# Process unknown kwargs
# ----------------------
self._process_kwargs(**dict(arg, **kwargs))
# Reset skip_invalid
# ------------------
self._skip_invalid = False | [
"def",
"__init__",
"(",
"self",
",",
"arg",
"=",
"None",
",",
"font",
"=",
"None",
",",
"side",
"=",
"None",
",",
"text",
"=",
"None",
",",
"*",
"*",
"kwargs",
")",
":",
"super",
"(",
"Title",
",",
"self",
")",
".",
"__init__",
"(",
"\"title\"",
")",
"if",
"\"_parent\"",
"in",
"kwargs",
":",
"self",
".",
"_parent",
"=",
"kwargs",
"[",
"\"_parent\"",
"]",
"return",
"# Validate arg",
"# ------------",
"if",
"arg",
"is",
"None",
":",
"arg",
"=",
"{",
"}",
"elif",
"isinstance",
"(",
"arg",
",",
"self",
".",
"__class__",
")",
":",
"arg",
"=",
"arg",
".",
"to_plotly_json",
"(",
")",
"elif",
"isinstance",
"(",
"arg",
",",
"dict",
")",
":",
"arg",
"=",
"_copy",
".",
"copy",
"(",
"arg",
")",
"else",
":",
"raise",
"ValueError",
"(",
"\"\"\"\\\nThe first argument to the plotly.graph_objs.mesh3d.colorbar.Title \nconstructor must be a dict or \nan instance of :class:`plotly.graph_objs.mesh3d.colorbar.Title`\"\"\"",
")",
"# Handle skip_invalid",
"# -------------------",
"self",
".",
"_skip_invalid",
"=",
"kwargs",
".",
"pop",
"(",
"\"skip_invalid\"",
",",
"False",
")",
"self",
".",
"_validate",
"=",
"kwargs",
".",
"pop",
"(",
"\"_validate\"",
",",
"True",
")",
"# Populate data dict with properties",
"# ----------------------------------",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"font\"",
",",
"None",
")",
"_v",
"=",
"font",
"if",
"font",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"font\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"side\"",
",",
"None",
")",
"_v",
"=",
"side",
"if",
"side",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"side\"",
"]",
"=",
"_v",
"_v",
"=",
"arg",
".",
"pop",
"(",
"\"text\"",
",",
"None",
")",
"_v",
"=",
"text",
"if",
"text",
"is",
"not",
"None",
"else",
"_v",
"if",
"_v",
"is",
"not",
"None",
":",
"self",
"[",
"\"text\"",
"]",
"=",
"_v",
"# Process unknown kwargs",
"# ----------------------",
"self",
".",
"_process_kwargs",
"(",
"*",
"*",
"dict",
"(",
"arg",
",",
"*",
"*",
"kwargs",
")",
")",
"# Reset skip_invalid",
"# ------------------",
"self",
".",
"_skip_invalid",
"=",
"False"
] | [
126,
4
] | [
203,
34
] | python | en | ['en', 'error', 'th'] | False |
create_wilderness | (name="default", mapprovider=None) |
Creates a new wilderness map. Does nothing if a wilderness map already
exists with the same name.
Args:
name (str, optional): the name to use for that wilderness map
mapprovider (WildernessMap instance, optional): an instance of a
WildernessMap class (or subclass) that will be used to provide the
layout of this wilderness map. If none is provided, the default
infinite grid map will be used.
|
Creates a new wilderness map. Does nothing if a wilderness map already
exists with the same name. | def create_wilderness(name="default", mapprovider=None):
"""
Creates a new wilderness map. Does nothing if a wilderness map already
exists with the same name.
Args:
name (str, optional): the name to use for that wilderness map
mapprovider (WildernessMap instance, optional): an instance of a
WildernessMap class (or subclass) that will be used to provide the
layout of this wilderness map. If none is provided, the default
infinite grid map will be used.
"""
if WildernessScript.objects.filter(db_key=name).exists():
# Don't create two wildernesses with the same name
return
if not mapprovider:
mapprovider = WildernessMapProvider()
script = create_script(WildernessScript, key=name)
script.db.mapprovider = mapprovider | [
"def",
"create_wilderness",
"(",
"name",
"=",
"\"default\"",
",",
"mapprovider",
"=",
"None",
")",
":",
"if",
"WildernessScript",
".",
"objects",
".",
"filter",
"(",
"db_key",
"=",
"name",
")",
".",
"exists",
"(",
")",
":",
"# Don't create two wildernesses with the same name",
"return",
"if",
"not",
"mapprovider",
":",
"mapprovider",
"=",
"WildernessMapProvider",
"(",
")",
"script",
"=",
"create_script",
"(",
"WildernessScript",
",",
"key",
"=",
"name",
")",
"script",
".",
"db",
".",
"mapprovider",
"=",
"mapprovider"
] | [
123,
0
] | [
143,
39
] | python | en | ['en', 'error', 'th'] | False |
enter_wilderness | (obj, coordinates=(0, 0), name="default") |
Moves obj into the wilderness. The wilderness needs to exist first and the
provided coordinates needs to be valid inside that wilderness.
Args:
obj (object): the object to move into the wilderness
coordinates (tuple), optional): the coordinates to move obj to into
the wilderness. If not provided, defaults (0, 0)
name (str, optional): name of the wilderness map, if not using the
default one
Returns:
bool: True if obj successfully moved into the wilderness.
|
Moves obj into the wilderness. The wilderness needs to exist first and the
provided coordinates needs to be valid inside that wilderness. | def enter_wilderness(obj, coordinates=(0, 0), name="default"):
"""
Moves obj into the wilderness. The wilderness needs to exist first and the
provided coordinates needs to be valid inside that wilderness.
Args:
obj (object): the object to move into the wilderness
coordinates (tuple), optional): the coordinates to move obj to into
the wilderness. If not provided, defaults (0, 0)
name (str, optional): name of the wilderness map, if not using the
default one
Returns:
bool: True if obj successfully moved into the wilderness.
"""
if not WildernessScript.objects.filter(db_key=name).exists():
return False
script = WildernessScript.objects.get(db_key=name)
if script.is_valid_coordinates(coordinates):
script.move_obj(obj, coordinates)
return True
else:
return False | [
"def",
"enter_wilderness",
"(",
"obj",
",",
"coordinates",
"=",
"(",
"0",
",",
"0",
")",
",",
"name",
"=",
"\"default\"",
")",
":",
"if",
"not",
"WildernessScript",
".",
"objects",
".",
"filter",
"(",
"db_key",
"=",
"name",
")",
".",
"exists",
"(",
")",
":",
"return",
"False",
"script",
"=",
"WildernessScript",
".",
"objects",
".",
"get",
"(",
"db_key",
"=",
"name",
")",
"if",
"script",
".",
"is_valid_coordinates",
"(",
"coordinates",
")",
":",
"script",
".",
"move_obj",
"(",
"obj",
",",
"coordinates",
")",
"return",
"True",
"else",
":",
"return",
"False"
] | [
146,
0
] | [
169,
20
] | python | en | ['en', 'error', 'th'] | False |
get_new_coordinates | (coordinates, direction) |
Returns the coordinates of direction applied to the provided coordinates.
Args:
coordinates: tuple of (x, y)
direction: a direction string (like "northeast")
Returns:
tuple: tuple of (x, y) coordinates
|
Returns the coordinates of direction applied to the provided coordinates. | def get_new_coordinates(coordinates, direction):
"""
Returns the coordinates of direction applied to the provided coordinates.
Args:
coordinates: tuple of (x, y)
direction: a direction string (like "northeast")
Returns:
tuple: tuple of (x, y) coordinates
"""
x, y = coordinates
if direction in ("north", "northwest", "northeast"):
y += 1
if direction in ("south", "southwest", "southeast"):
y -= 1
if direction in ("northwest", "west", "southwest"):
x -= 1
if direction in ("northeast", "east", "southeast"):
x += 1
return (x, y) | [
"def",
"get_new_coordinates",
"(",
"coordinates",
",",
"direction",
")",
":",
"x",
",",
"y",
"=",
"coordinates",
"if",
"direction",
"in",
"(",
"\"north\"",
",",
"\"northwest\"",
",",
"\"northeast\"",
")",
":",
"y",
"+=",
"1",
"if",
"direction",
"in",
"(",
"\"south\"",
",",
"\"southwest\"",
",",
"\"southeast\"",
")",
":",
"y",
"-=",
"1",
"if",
"direction",
"in",
"(",
"\"northwest\"",
",",
"\"west\"",
",",
"\"southwest\"",
")",
":",
"x",
"-=",
"1",
"if",
"direction",
"in",
"(",
"\"northeast\"",
",",
"\"east\"",
",",
"\"southeast\"",
")",
":",
"x",
"+=",
"1",
"return",
"(",
"x",
",",
"y",
")"
] | [
172,
0
] | [
194,
17
] | python | en | ['en', 'error', 'th'] | False |
WildernessScript.at_script_creation | (self) |
Only called once, when the script is created. This is a default Evennia
hook.
|
Only called once, when the script is created. This is a default Evennia
hook.
| def at_script_creation(self):
"""
Only called once, when the script is created. This is a default Evennia
hook.
"""
self.persistent = True
# Store the coordinates of every item that is inside the wilderness
# Key: object, Value: (x, y)
self.db.itemcoordinates = {}
# Store the rooms that are used as views into the wilderness
# Key: (x, y), Value: room object
self.db.rooms = {}
# Created rooms that are not needed anymore are stored there. This
# allows quick retrieval if a new room is needed without having to
# create it.
self.db.unused_rooms = [] | [
"def",
"at_script_creation",
"(",
"self",
")",
":",
"self",
".",
"persistent",
"=",
"True",
"# Store the coordinates of every item that is inside the wilderness",
"# Key: object, Value: (x, y)",
"self",
".",
"db",
".",
"itemcoordinates",
"=",
"{",
"}",
"# Store the rooms that are used as views into the wilderness",
"# Key: (x, y), Value: room object",
"self",
".",
"db",
".",
"rooms",
"=",
"{",
"}",
"# Created rooms that are not needed anymore are stored there. This",
"# allows quick retrieval if a new room is needed without having to",
"# create it.",
"self",
".",
"db",
".",
"unused_rooms",
"=",
"[",
"]"
] | [
205,
4
] | [
223,
33
] | python | en | ['en', 'error', 'th'] | False |
WildernessScript.mapprovider | (self) |
Shortcut property to the map provider.
Returns:
MapProvider: the mapprovider used with this wilderness
|
Shortcut property to the map provider. | def mapprovider(self):
"""
Shortcut property to the map provider.
Returns:
MapProvider: the mapprovider used with this wilderness
"""
return self.db.mapprovider | [
"def",
"mapprovider",
"(",
"self",
")",
":",
"return",
"self",
".",
"db",
".",
"mapprovider"
] | [
226,
4
] | [
233,
34
] | python | en | ['en', 'error', 'th'] | False |
WildernessScript.itemcoordinates | (self) |
Returns a dictionary with the coordinates of every item inside this
wilderness map. The key is the item, the value are the coordinates as
(x, y) tuple.
Returns:
{item: coordinates}
|
Returns a dictionary with the coordinates of every item inside this
wilderness map. The key is the item, the value are the coordinates as
(x, y) tuple. | def itemcoordinates(self):
"""
Returns a dictionary with the coordinates of every item inside this
wilderness map. The key is the item, the value are the coordinates as
(x, y) tuple.
Returns:
{item: coordinates}
"""
return self.db.itemcoordinates | [
"def",
"itemcoordinates",
"(",
"self",
")",
":",
"return",
"self",
".",
"db",
".",
"itemcoordinates"
] | [
236,
4
] | [
245,
38
] | python | en | ['en', 'error', 'th'] | False |
WildernessScript.at_start | (self) |
Called when the script is started and also after server reloads.
|
Called when the script is started and also after server reloads.
| def at_start(self):
"""
Called when the script is started and also after server reloads.
"""
for coordinates, room in self.db.rooms.items():
room.ndb.wildernessscript = self
room.ndb.active_coordinates = coordinates
for item in self.db.itemcoordinates.keys():
# Items deleted from the wilderness leave None type 'ghosts'
# that must be cleaned out
if item is None:
del self.db.itemcoordinates[item]
continue
item.ndb.wilderness = self | [
"def",
"at_start",
"(",
"self",
")",
":",
"for",
"coordinates",
",",
"room",
"in",
"self",
".",
"db",
".",
"rooms",
".",
"items",
"(",
")",
":",
"room",
".",
"ndb",
".",
"wildernessscript",
"=",
"self",
"room",
".",
"ndb",
".",
"active_coordinates",
"=",
"coordinates",
"for",
"item",
"in",
"self",
".",
"db",
".",
"itemcoordinates",
".",
"keys",
"(",
")",
":",
"# Items deleted from the wilderness leave None type 'ghosts'",
"# that must be cleaned out",
"if",
"item",
"is",
"None",
":",
"del",
"self",
".",
"db",
".",
"itemcoordinates",
"[",
"item",
"]",
"continue",
"item",
".",
"ndb",
".",
"wilderness",
"=",
"self"
] | [
247,
4
] | [
260,
38
] | python | en | ['en', 'error', 'th'] | False |
WildernessScript.is_valid_coordinates | (self, coordinates) |
Returns True if coordinates are valid (and can be travelled to).
Otherwise returns False
Args:
coordinates (tuple): coordinates as (x, y) tuple
Returns:
bool: True if the coordinates are valid
|
Returns True if coordinates are valid (and can be travelled to).
Otherwise returns False | def is_valid_coordinates(self, coordinates):
"""
Returns True if coordinates are valid (and can be travelled to).
Otherwise returns False
Args:
coordinates (tuple): coordinates as (x, y) tuple
Returns:
bool: True if the coordinates are valid
"""
return self.mapprovider.is_valid_coordinates(self, coordinates) | [
"def",
"is_valid_coordinates",
"(",
"self",
",",
"coordinates",
")",
":",
"return",
"self",
".",
"mapprovider",
".",
"is_valid_coordinates",
"(",
"self",
",",
"coordinates",
")"
] | [
262,
4
] | [
273,
71
] | python | en | ['en', 'error', 'th'] | False |
WildernessScript.get_obj_coordinates | (self, obj) |
Returns the coordinates of obj in the wilderness.
Returns (x, y)
Args:
obj (object): an object inside the wilderness
Returns:
tuple: (x, y) tuple of where obj is located
|
Returns the coordinates of obj in the wilderness. | def get_obj_coordinates(self, obj):
"""
Returns the coordinates of obj in the wilderness.
Returns (x, y)
Args:
obj (object): an object inside the wilderness
Returns:
tuple: (x, y) tuple of where obj is located
"""
return self.itemcoordinates[obj] | [
"def",
"get_obj_coordinates",
"(",
"self",
",",
"obj",
")",
":",
"return",
"self",
".",
"itemcoordinates",
"[",
"obj",
"]"
] | [
275,
4
] | [
287,
40
] | python | en | ['en', 'error', 'th'] | False |
WildernessScript.get_objs_at_coordinates | (self, coordinates) |
Returns a list of every object at certain coordinates.
Imeplementation detail: this uses a naive iteration through every
object inside the wilderness which could cause slow downs when there
are a lot of objects in the map.
Args:
coordinates (tuple): a coordinate tuple like (x, y)
Returns:
[Object, ]: list of Objects at coordinates
|
Returns a list of every object at certain coordinates. | def get_objs_at_coordinates(self, coordinates):
"""
Returns a list of every object at certain coordinates.
Imeplementation detail: this uses a naive iteration through every
object inside the wilderness which could cause slow downs when there
are a lot of objects in the map.
Args:
coordinates (tuple): a coordinate tuple like (x, y)
Returns:
[Object, ]: list of Objects at coordinates
"""
result = []
for item, item_coordinates in self.itemcoordinates.items():
# Items deleted from the wilderness leave None type 'ghosts'
# that must be cleaned out
if item is None:
del self.db.itemcoordinates[item]
continue
if coordinates == item_coordinates:
result.append(item)
return result | [
"def",
"get_objs_at_coordinates",
"(",
"self",
",",
"coordinates",
")",
":",
"result",
"=",
"[",
"]",
"for",
"item",
",",
"item_coordinates",
"in",
"self",
".",
"itemcoordinates",
".",
"items",
"(",
")",
":",
"# Items deleted from the wilderness leave None type 'ghosts'",
"# that must be cleaned out",
"if",
"item",
"is",
"None",
":",
"del",
"self",
".",
"db",
".",
"itemcoordinates",
"[",
"item",
"]",
"continue",
"if",
"coordinates",
"==",
"item_coordinates",
":",
"result",
".",
"append",
"(",
"item",
")",
"return",
"result"
] | [
289,
4
] | [
312,
21
] | python | en | ['en', 'error', 'th'] | False |
WildernessScript.move_obj | (self, obj, new_coordinates) |
Moves obj to new coordinates in this wilderness.
Args:
obj (object): the object to move
new_coordinates (tuple): tuple of (x, y) where to move obj to.
|
Moves obj to new coordinates in this wilderness. | def move_obj(self, obj, new_coordinates):
"""
Moves obj to new coordinates in this wilderness.
Args:
obj (object): the object to move
new_coordinates (tuple): tuple of (x, y) where to move obj to.
"""
# Update the position of this obj in the wilderness
self.itemcoordinates[obj] = new_coordinates
old_room = obj.location
# Remove the obj's location. This is needed so that the object does not
# appear in its old room should that room be deleted.
obj.location = None
try:
# See if we already have a room for that location
room = self.db.rooms[new_coordinates]
# There is. Try to destroy the old_room if it is not needed anymore
self._destroy_room(old_room)
except KeyError:
# There is no room yet at new_location
if (old_room and not inherits_from(old_room, WildernessRoom)) or \
(not old_room):
# Obj doesn't originally come from a wilderness room.
# We'll create a new one then.
room = self._create_room(new_coordinates, obj)
else:
# Obj does come from another wilderness room
create_new_room = False
if old_room.wilderness != self:
# ... but that other wilderness room belongs to another
# wilderness map
create_new_room = True
old_room.wilderness.at_after_object_leave(obj)
else:
for item in old_room.contents:
if item.has_account:
# There is still a player in the old room.
# Let's create a new room and not touch that old
# room.
create_new_room = True
break
if create_new_room:
# Create a new room to hold obj, not touching any obj's in
# the old room
room = self._create_room(new_coordinates, obj)
else:
# The old_room is empty: we are just going to reuse that
# room instead of creating a new one
room = old_room
room.set_active_coordinates(new_coordinates, obj)
obj.location = room
obj.ndb.wilderness = self | [
"def",
"move_obj",
"(",
"self",
",",
"obj",
",",
"new_coordinates",
")",
":",
"# Update the position of this obj in the wilderness",
"self",
".",
"itemcoordinates",
"[",
"obj",
"]",
"=",
"new_coordinates",
"old_room",
"=",
"obj",
".",
"location",
"# Remove the obj's location. This is needed so that the object does not",
"# appear in its old room should that room be deleted.",
"obj",
".",
"location",
"=",
"None",
"try",
":",
"# See if we already have a room for that location",
"room",
"=",
"self",
".",
"db",
".",
"rooms",
"[",
"new_coordinates",
"]",
"# There is. Try to destroy the old_room if it is not needed anymore",
"self",
".",
"_destroy_room",
"(",
"old_room",
")",
"except",
"KeyError",
":",
"# There is no room yet at new_location",
"if",
"(",
"old_room",
"and",
"not",
"inherits_from",
"(",
"old_room",
",",
"WildernessRoom",
")",
")",
"or",
"(",
"not",
"old_room",
")",
":",
"# Obj doesn't originally come from a wilderness room.",
"# We'll create a new one then.",
"room",
"=",
"self",
".",
"_create_room",
"(",
"new_coordinates",
",",
"obj",
")",
"else",
":",
"# Obj does come from another wilderness room",
"create_new_room",
"=",
"False",
"if",
"old_room",
".",
"wilderness",
"!=",
"self",
":",
"# ... but that other wilderness room belongs to another",
"# wilderness map",
"create_new_room",
"=",
"True",
"old_room",
".",
"wilderness",
".",
"at_after_object_leave",
"(",
"obj",
")",
"else",
":",
"for",
"item",
"in",
"old_room",
".",
"contents",
":",
"if",
"item",
".",
"has_account",
":",
"# There is still a player in the old room.",
"# Let's create a new room and not touch that old",
"# room.",
"create_new_room",
"=",
"True",
"break",
"if",
"create_new_room",
":",
"# Create a new room to hold obj, not touching any obj's in",
"# the old room",
"room",
"=",
"self",
".",
"_create_room",
"(",
"new_coordinates",
",",
"obj",
")",
"else",
":",
"# The old_room is empty: we are just going to reuse that",
"# room instead of creating a new one",
"room",
"=",
"old_room",
"room",
".",
"set_active_coordinates",
"(",
"new_coordinates",
",",
"obj",
")",
"obj",
".",
"location",
"=",
"room",
"obj",
".",
"ndb",
".",
"wilderness",
"=",
"self"
] | [
314,
4
] | [
371,
33
] | python | en | ['en', 'error', 'th'] | False |
WildernessScript._create_room | (self, coordinates, report_to) |
Gets a new WildernessRoom to be used for the provided coordinates.
It first tries to retrieve a room out of storage. If there are no rooms
left a new one will be created.
Args:
coordinates (tuple): coordinate tuple of (x, y)
report_to (object): the obj to return error messages to
|
Gets a new WildernessRoom to be used for the provided coordinates. | def _create_room(self, coordinates, report_to):
"""
Gets a new WildernessRoom to be used for the provided coordinates.
It first tries to retrieve a room out of storage. If there are no rooms
left a new one will be created.
Args:
coordinates (tuple): coordinate tuple of (x, y)
report_to (object): the obj to return error messages to
"""
if self.db.unused_rooms:
# There is still unused rooms stored in storage, let's get one of
# those
room = self.db.unused_rooms.pop()
else:
# No more unused rooms...time to make a new one.
# First, create the room
room = create_object(typeclass=self.mapprovider.room_typeclass,
key="Wilderness",
report_to=report_to)
# Then the exits
exits = [("north", "n"),
("northeast", "ne"),
("east", "e"),
("southeast", "se"),
("south", "s"),
("southwest", "sw"),
("west", "w"),
("northwest", "nw")]
for key, alias in exits:
create_object(typeclass=self.mapprovider.exit_typeclass,
key=key,
aliases=[alias],
location=room,
destination=room,
report_to=report_to)
room.ndb.active_coordinates = coordinates
room.ndb.wildernessscript = self
self.db.rooms[coordinates] = room
return room | [
"def",
"_create_room",
"(",
"self",
",",
"coordinates",
",",
"report_to",
")",
":",
"if",
"self",
".",
"db",
".",
"unused_rooms",
":",
"# There is still unused rooms stored in storage, let's get one of",
"# those",
"room",
"=",
"self",
".",
"db",
".",
"unused_rooms",
".",
"pop",
"(",
")",
"else",
":",
"# No more unused rooms...time to make a new one.",
"# First, create the room",
"room",
"=",
"create_object",
"(",
"typeclass",
"=",
"self",
".",
"mapprovider",
".",
"room_typeclass",
",",
"key",
"=",
"\"Wilderness\"",
",",
"report_to",
"=",
"report_to",
")",
"# Then the exits",
"exits",
"=",
"[",
"(",
"\"north\"",
",",
"\"n\"",
")",
",",
"(",
"\"northeast\"",
",",
"\"ne\"",
")",
",",
"(",
"\"east\"",
",",
"\"e\"",
")",
",",
"(",
"\"southeast\"",
",",
"\"se\"",
")",
",",
"(",
"\"south\"",
",",
"\"s\"",
")",
",",
"(",
"\"southwest\"",
",",
"\"sw\"",
")",
",",
"(",
"\"west\"",
",",
"\"w\"",
")",
",",
"(",
"\"northwest\"",
",",
"\"nw\"",
")",
"]",
"for",
"key",
",",
"alias",
"in",
"exits",
":",
"create_object",
"(",
"typeclass",
"=",
"self",
".",
"mapprovider",
".",
"exit_typeclass",
",",
"key",
"=",
"key",
",",
"aliases",
"=",
"[",
"alias",
"]",
",",
"location",
"=",
"room",
",",
"destination",
"=",
"room",
",",
"report_to",
"=",
"report_to",
")",
"room",
".",
"ndb",
".",
"active_coordinates",
"=",
"coordinates",
"room",
".",
"ndb",
".",
"wildernessscript",
"=",
"self",
"self",
".",
"db",
".",
"rooms",
"[",
"coordinates",
"]",
"=",
"room",
"return",
"room"
] | [
373,
4
] | [
417,
19
] | python | en | ['en', 'error', 'th'] | False |
WildernessScript._destroy_room | (self, room) |
Moves a room back to storage. If room is not a WildernessRoom or there
is a player inside the room, then this does nothing.
Args:
room (WildernessRoom): the room to put in storage
|
Moves a room back to storage. If room is not a WildernessRoom or there
is a player inside the room, then this does nothing. | def _destroy_room(self, room):
"""
Moves a room back to storage. If room is not a WildernessRoom or there
is a player inside the room, then this does nothing.
Args:
room (WildernessRoom): the room to put in storage
"""
if not room or not inherits_from(room, WildernessRoom):
return
for item in room.contents:
if item.has_account:
# There is still a character in that room. We can't get rid of
# it just yet
break
else:
# No characters left in the room.
# Clear the location of every obj in that room first
for item in room.contents:
if item.destination and item.destination == room:
# Ignore the exits, they stay in the room
continue
item.location = None
# Then delete its reference
del self.db.rooms[room.ndb.active_coordinates]
# And finally put this room away in storage
self.db.unused_rooms.append(room) | [
"def",
"_destroy_room",
"(",
"self",
",",
"room",
")",
":",
"if",
"not",
"room",
"or",
"not",
"inherits_from",
"(",
"room",
",",
"WildernessRoom",
")",
":",
"return",
"for",
"item",
"in",
"room",
".",
"contents",
":",
"if",
"item",
".",
"has_account",
":",
"# There is still a character in that room. We can't get rid of",
"# it just yet",
"break",
"else",
":",
"# No characters left in the room.",
"# Clear the location of every obj in that room first",
"for",
"item",
"in",
"room",
".",
"contents",
":",
"if",
"item",
".",
"destination",
"and",
"item",
".",
"destination",
"==",
"room",
":",
"# Ignore the exits, they stay in the room",
"continue",
"item",
".",
"location",
"=",
"None",
"# Then delete its reference",
"del",
"self",
".",
"db",
".",
"rooms",
"[",
"room",
".",
"ndb",
".",
"active_coordinates",
"]",
"# And finally put this room away in storage",
"self",
".",
"db",
".",
"unused_rooms",
".",
"append",
"(",
"room",
")"
] | [
419,
4
] | [
448,
45
] | python | en | ['en', 'error', 'th'] | False |
WildernessScript.at_after_object_leave | (self, obj) |
Called after an object left this wilderness map. Used for cleaning up.
Args:
obj (object): the object that left
|
Called after an object left this wilderness map. Used for cleaning up. | def at_after_object_leave(self, obj):
"""
Called after an object left this wilderness map. Used for cleaning up.
Args:
obj (object): the object that left
"""
# Remove that obj from the wilderness's coordinates dict
loc = self.db.itemcoordinates[obj]
del self.db.itemcoordinates[obj]
# And see if we can put that room away into storage.
room = self.db.rooms[loc]
self._destroy_room(room) | [
"def",
"at_after_object_leave",
"(",
"self",
",",
"obj",
")",
":",
"# Remove that obj from the wilderness's coordinates dict",
"loc",
"=",
"self",
".",
"db",
".",
"itemcoordinates",
"[",
"obj",
"]",
"del",
"self",
".",
"db",
".",
"itemcoordinates",
"[",
"obj",
"]",
"# And see if we can put that room away into storage.",
"room",
"=",
"self",
".",
"db",
".",
"rooms",
"[",
"loc",
"]",
"self",
".",
"_destroy_room",
"(",
"room",
")"
] | [
450,
4
] | [
463,
32
] | python | en | ['en', 'error', 'th'] | False |
WildernessRoom.wilderness | (self) |
Shortcut property to the wilderness script this room belongs to.
Returns:
WildernessScript: the WildernessScript attached to this room
|
Shortcut property to the wilderness script this room belongs to. | def wilderness(self):
"""
Shortcut property to the wilderness script this room belongs to.
Returns:
WildernessScript: the WildernessScript attached to this room
"""
return self.ndb.wildernessscript | [
"def",
"wilderness",
"(",
"self",
")",
":",
"return",
"self",
".",
"ndb",
".",
"wildernessscript"
] | [
475,
4
] | [
482,
40
] | python | en | ['en', 'error', 'th'] | False |
WildernessRoom.location_name | (self) |
Returns the name of the wilderness at this room's coordinates.
Returns:
name (str)
|
Returns the name of the wilderness at this room's coordinates. | def location_name(self):
"""
Returns the name of the wilderness at this room's coordinates.
Returns:
name (str)
"""
return self.wilderness.mapprovider.get_location_name(
self.coordinates) | [
"def",
"location_name",
"(",
"self",
")",
":",
"return",
"self",
".",
"wilderness",
".",
"mapprovider",
".",
"get_location_name",
"(",
"self",
".",
"coordinates",
")"
] | [
485,
4
] | [
493,
29
] | python | en | ['en', 'error', 'th'] | False |
WildernessRoom.coordinates | (self) |
Returns the coordinates of this room into the wilderness.
Returns:
tuple: (x, y) coordinates of where this room is inside the
wilderness.
|
Returns the coordinates of this room into the wilderness. | def coordinates(self):
"""
Returns the coordinates of this room into the wilderness.
Returns:
tuple: (x, y) coordinates of where this room is inside the
wilderness.
"""
return self.ndb.active_coordinates | [
"def",
"coordinates",
"(",
"self",
")",
":",
"return",
"self",
".",
"ndb",
".",
"active_coordinates"
] | [
496,
4
] | [
504,
42
] | python | en | ['en', 'error', 'th'] | False |
WildernessRoom.at_object_receive | (self, moved_obj, source_location) |
Called after an object has been moved into this object. This is a
default Evennia hook.
Args:
moved_obj (Object): The object moved into this one.
source_location (Object): Where `moved_obj` came from.
|
Called after an object has been moved into this object. This is a
default Evennia hook. | def at_object_receive(self, moved_obj, source_location):
"""
Called after an object has been moved into this object. This is a
default Evennia hook.
Args:
moved_obj (Object): The object moved into this one.
source_location (Object): Where `moved_obj` came from.
"""
if isinstance(moved_obj, WildernessExit):
# Ignore exits looping back to themselves: those are the regular
# n, ne, ... exits.
return
itemcoords = self.wilderness.db.itemcoordinates
if moved_obj in itemcoords:
# This object was already in the wilderness. We need to make sure
# it goes to the correct room it belongs to.
# Otherwise the following issue can come up:
# 1) Player 1 and Player 2 share a room
# 2) Player 1 disconnects
# 3) Player 2 moves around
# 4) Player 1 reconnects
# Player 1 will end up in player 2's room, which has the wrong
# coordinates
coordinates = itemcoords[moved_obj]
# Setting the location to None is important here so that we always
# get a "fresh" room
moved_obj.location = None
self.wilderness.move_obj(moved_obj, coordinates)
else:
# This object wasn't in the wilderness yet. Let's add it.
itemcoords[moved_obj] = self.coordinates | [
"def",
"at_object_receive",
"(",
"self",
",",
"moved_obj",
",",
"source_location",
")",
":",
"if",
"isinstance",
"(",
"moved_obj",
",",
"WildernessExit",
")",
":",
"# Ignore exits looping back to themselves: those are the regular",
"# n, ne, ... exits.",
"return",
"itemcoords",
"=",
"self",
".",
"wilderness",
".",
"db",
".",
"itemcoordinates",
"if",
"moved_obj",
"in",
"itemcoords",
":",
"# This object was already in the wilderness. We need to make sure",
"# it goes to the correct room it belongs to.",
"# Otherwise the following issue can come up:",
"# 1) Player 1 and Player 2 share a room",
"# 2) Player 1 disconnects",
"# 3) Player 2 moves around",
"# 4) Player 1 reconnects",
"# Player 1 will end up in player 2's room, which has the wrong",
"# coordinates",
"coordinates",
"=",
"itemcoords",
"[",
"moved_obj",
"]",
"# Setting the location to None is important here so that we always",
"# get a \"fresh\" room",
"moved_obj",
".",
"location",
"=",
"None",
"self",
".",
"wilderness",
".",
"move_obj",
"(",
"moved_obj",
",",
"coordinates",
")",
"else",
":",
"# This object wasn't in the wilderness yet. Let's add it.",
"itemcoords",
"[",
"moved_obj",
"]",
"=",
"self",
".",
"coordinates"
] | [
506,
4
] | [
539,
52
] | python | en | ['en', 'error', 'th'] | False |
WildernessRoom.at_object_leave | (self, moved_obj, target_location) |
Called just before an object leaves from inside this object. This is a
default Evennia hook.
Args:
moved_obj (Object): The object leaving
target_location (Object): Where `moved_obj` is going.
|
Called just before an object leaves from inside this object. This is a
default Evennia hook. | def at_object_leave(self, moved_obj, target_location):
"""
Called just before an object leaves from inside this object. This is a
default Evennia hook.
Args:
moved_obj (Object): The object leaving
target_location (Object): Where `moved_obj` is going.
"""
self.wilderness.at_after_object_leave(moved_obj) | [
"def",
"at_object_leave",
"(",
"self",
",",
"moved_obj",
",",
"target_location",
")",
":",
"self",
".",
"wilderness",
".",
"at_after_object_leave",
"(",
"moved_obj",
")"
] | [
541,
4
] | [
551,
56
] | python | en | ['en', 'error', 'th'] | False |
WildernessRoom.set_active_coordinates | (self, new_coordinates, obj) |
Changes this room to show the wilderness map from other coordinates.
Args:
new_coordinates (tuple): coordinates as tuple of (x, y)
obj (Object): the object that moved into this room and caused the
coordinates to change
|
Changes this room to show the wilderness map from other coordinates. | def set_active_coordinates(self, new_coordinates, obj):
"""
Changes this room to show the wilderness map from other coordinates.
Args:
new_coordinates (tuple): coordinates as tuple of (x, y)
obj (Object): the object that moved into this room and caused the
coordinates to change
"""
# Remove the reference for the old coordinates...
rooms = self.wilderness.db.rooms
del rooms[self.coordinates]
# ...and add it for the new coordinates.
self.ndb.active_coordinates = new_coordinates
rooms[self.coordinates] = self
# Every obj inside this room will get its location set to None
for item in self.contents:
if not item.destination or item.destination != item.location:
item.location = None
# And every obj matching the new coordinates will get its location set
# to this room
for item in self.wilderness.get_objs_at_coordinates(new_coordinates):
item.location = self
# Fix the lockfuncs for the exit so we can't go where we're not
# supposed to go
for exit in self.exits:
if exit.destination != self:
continue
x, y = get_new_coordinates(new_coordinates, exit.key)
valid = self.wilderness.is_valid_coordinates((x, y))
if valid:
exit.locks.add("traverse:true();view:true()")
else:
exit.locks.add("traverse:false();view:false()")
# Finally call the at_prepare_room hook to give a chance to further
# customise it
self.wilderness.mapprovider.at_prepare_room(new_coordinates, obj, self) | [
"def",
"set_active_coordinates",
"(",
"self",
",",
"new_coordinates",
",",
"obj",
")",
":",
"# Remove the reference for the old coordinates...",
"rooms",
"=",
"self",
".",
"wilderness",
".",
"db",
".",
"rooms",
"del",
"rooms",
"[",
"self",
".",
"coordinates",
"]",
"# ...and add it for the new coordinates.",
"self",
".",
"ndb",
".",
"active_coordinates",
"=",
"new_coordinates",
"rooms",
"[",
"self",
".",
"coordinates",
"]",
"=",
"self",
"# Every obj inside this room will get its location set to None",
"for",
"item",
"in",
"self",
".",
"contents",
":",
"if",
"not",
"item",
".",
"destination",
"or",
"item",
".",
"destination",
"!=",
"item",
".",
"location",
":",
"item",
".",
"location",
"=",
"None",
"# And every obj matching the new coordinates will get its location set",
"# to this room",
"for",
"item",
"in",
"self",
".",
"wilderness",
".",
"get_objs_at_coordinates",
"(",
"new_coordinates",
")",
":",
"item",
".",
"location",
"=",
"self",
"# Fix the lockfuncs for the exit so we can't go where we're not",
"# supposed to go",
"for",
"exit",
"in",
"self",
".",
"exits",
":",
"if",
"exit",
".",
"destination",
"!=",
"self",
":",
"continue",
"x",
",",
"y",
"=",
"get_new_coordinates",
"(",
"new_coordinates",
",",
"exit",
".",
"key",
")",
"valid",
"=",
"self",
".",
"wilderness",
".",
"is_valid_coordinates",
"(",
"(",
"x",
",",
"y",
")",
")",
"if",
"valid",
":",
"exit",
".",
"locks",
".",
"add",
"(",
"\"traverse:true();view:true()\"",
")",
"else",
":",
"exit",
".",
"locks",
".",
"add",
"(",
"\"traverse:false();view:false()\"",
")",
"# Finally call the at_prepare_room hook to give a chance to further",
"# customise it",
"self",
".",
"wilderness",
".",
"mapprovider",
".",
"at_prepare_room",
"(",
"new_coordinates",
",",
"obj",
",",
"self",
")"
] | [
553,
4
] | [
593,
79
] | python | en | ['en', 'error', 'th'] | False |
WildernessRoom.get_display_name | (self, looker, **kwargs) |
Displays the name of the object in a viewer-aware manner.
Args:
looker (TypedObject): The object or account that is looking
at/getting inforamtion for this object.
Returns:
name (str): A string containing the name of the object,
including the DBREF if this user is privileged to control
said object and also its coordinates into the wilderness map.
Notes:
This function could be extended to change how object names
appear to users in character, but be wary. This function
does not change an object's keys or aliases when
searching, and is expected to produce something useful for
builders.
|
Displays the name of the object in a viewer-aware manner. | def get_display_name(self, looker, **kwargs):
"""
Displays the name of the object in a viewer-aware manner.
Args:
looker (TypedObject): The object or account that is looking
at/getting inforamtion for this object.
Returns:
name (str): A string containing the name of the object,
including the DBREF if this user is privileged to control
said object and also its coordinates into the wilderness map.
Notes:
This function could be extended to change how object names
appear to users in character, but be wary. This function
does not change an object's keys or aliases when
searching, and is expected to produce something useful for
builders.
"""
if self.locks.check_lockstring(looker, "perm(Builder)"):
name = "{}(#{})".format(self.location_name, self.id)
else:
name = self.location_name
name += " {0}".format(self.coordinates)
return name | [
"def",
"get_display_name",
"(",
"self",
",",
"looker",
",",
"*",
"*",
"kwargs",
")",
":",
"if",
"self",
".",
"locks",
".",
"check_lockstring",
"(",
"looker",
",",
"\"perm(Builder)\"",
")",
":",
"name",
"=",
"\"{}(#{})\"",
".",
"format",
"(",
"self",
".",
"location_name",
",",
"self",
".",
"id",
")",
"else",
":",
"name",
"=",
"self",
".",
"location_name",
"name",
"+=",
"\" {0}\"",
".",
"format",
"(",
"self",
".",
"coordinates",
")",
"return",
"name"
] | [
595,
4
] | [
621,
19
] | python | en | ['en', 'error', 'th'] | False |
WildernessExit.wilderness | (self) |
Shortcut property to the wilderness script.
Returns:
WildernessScript: the WildernessScript attached to this exit's room
|
Shortcut property to the wilderness script. | def wilderness(self):
"""
Shortcut property to the wilderness script.
Returns:
WildernessScript: the WildernessScript attached to this exit's room
"""
return self.location.wilderness | [
"def",
"wilderness",
"(",
"self",
")",
":",
"return",
"self",
".",
"location",
".",
"wilderness"
] | [
633,
4
] | [
640,
39
] | python | en | ['en', 'error', 'th'] | False |
WildernessExit.mapprovider | (self) |
Shortcut property to the map provider.
Returns:
MapProvider object: the mapprovider object used with this
wilderness map.
|
Shortcut property to the map provider. | def mapprovider(self):
"""
Shortcut property to the map provider.
Returns:
MapProvider object: the mapprovider object used with this
wilderness map.
"""
return self.wilderness.mapprovider | [
"def",
"mapprovider",
"(",
"self",
")",
":",
"return",
"self",
".",
"wilderness",
".",
"mapprovider"
] | [
643,
4
] | [
651,
42
] | python | en | ['en', 'error', 'th'] | False |
WildernessExit.at_traverse_coordinates | (self, traversing_object, current_coordinates,
new_coordinates) |
Called when an object wants to travel from one place inside the
wilderness to another place inside the wilderness.
If this returns True, then the traversing can happen. Otherwise it will
be blocked.
This method is similar how the `at_traverse` works on normal exits.
Args:
traversing_object (Object): The object doing the travelling.
current_coordinates (tuple): (x, y) coordinates where
`traversing_object` currently is.
new_coordinates (tuple): (x, y) coordinates of where
`traversing_object` wants to travel to.
Returns:
bool: True if traversing_object is allowed to traverse
|
Called when an object wants to travel from one place inside the
wilderness to another place inside the wilderness. | def at_traverse_coordinates(self, traversing_object, current_coordinates,
new_coordinates):
"""
Called when an object wants to travel from one place inside the
wilderness to another place inside the wilderness.
If this returns True, then the traversing can happen. Otherwise it will
be blocked.
This method is similar how the `at_traverse` works on normal exits.
Args:
traversing_object (Object): The object doing the travelling.
current_coordinates (tuple): (x, y) coordinates where
`traversing_object` currently is.
new_coordinates (tuple): (x, y) coordinates of where
`traversing_object` wants to travel to.
Returns:
bool: True if traversing_object is allowed to traverse
"""
return True | [
"def",
"at_traverse_coordinates",
"(",
"self",
",",
"traversing_object",
",",
"current_coordinates",
",",
"new_coordinates",
")",
":",
"return",
"True"
] | [
653,
4
] | [
674,
19
] | python | en | ['en', 'error', 'th'] | False |
WildernessExit.at_traverse | (self, traversing_object, target_location) |
This implements the actual traversal. The traverse lock has
already been checked (in the Exit command) at this point.
Args:
traversing_object (Object): Object traversing us.
target_location (Object): Where target is going.
Returns:
bool: True if the traverse is allowed to happen
|
This implements the actual traversal. The traverse lock has
already been checked (in the Exit command) at this point. | def at_traverse(self, traversing_object, target_location):
"""
This implements the actual traversal. The traverse lock has
already been checked (in the Exit command) at this point.
Args:
traversing_object (Object): Object traversing us.
target_location (Object): Where target is going.
Returns:
bool: True if the traverse is allowed to happen
"""
itemcoordinates = self.location.wilderness.db.itemcoordinates
current_coordinates = itemcoordinates[traversing_object]
new_coordinates = get_new_coordinates(current_coordinates, self.key)
if not self.at_traverse_coordinates(traversing_object,
current_coordinates,
new_coordinates):
return False
if not traversing_object.at_before_move(None):
return False
traversing_object.location.msg_contents("{} leaves to {}".format(
traversing_object.key, new_coordinates),
exclude=[traversing_object])
self.location.wilderness.move_obj(traversing_object, new_coordinates)
traversing_object.location.msg_contents("{} arrives from {}".format(
traversing_object.key, current_coordinates),
exclude=[traversing_object])
traversing_object.at_after_move(None)
return True | [
"def",
"at_traverse",
"(",
"self",
",",
"traversing_object",
",",
"target_location",
")",
":",
"itemcoordinates",
"=",
"self",
".",
"location",
".",
"wilderness",
".",
"db",
".",
"itemcoordinates",
"current_coordinates",
"=",
"itemcoordinates",
"[",
"traversing_object",
"]",
"new_coordinates",
"=",
"get_new_coordinates",
"(",
"current_coordinates",
",",
"self",
".",
"key",
")",
"if",
"not",
"self",
".",
"at_traverse_coordinates",
"(",
"traversing_object",
",",
"current_coordinates",
",",
"new_coordinates",
")",
":",
"return",
"False",
"if",
"not",
"traversing_object",
".",
"at_before_move",
"(",
"None",
")",
":",
"return",
"False",
"traversing_object",
".",
"location",
".",
"msg_contents",
"(",
"\"{} leaves to {}\"",
".",
"format",
"(",
"traversing_object",
".",
"key",
",",
"new_coordinates",
")",
",",
"exclude",
"=",
"[",
"traversing_object",
"]",
")",
"self",
".",
"location",
".",
"wilderness",
".",
"move_obj",
"(",
"traversing_object",
",",
"new_coordinates",
")",
"traversing_object",
".",
"location",
".",
"msg_contents",
"(",
"\"{} arrives from {}\"",
".",
"format",
"(",
"traversing_object",
".",
"key",
",",
"current_coordinates",
")",
",",
"exclude",
"=",
"[",
"traversing_object",
"]",
")",
"traversing_object",
".",
"at_after_move",
"(",
"None",
")",
"return",
"True"
] | [
676,
4
] | [
712,
19
] | python | en | ['en', 'error', 'th'] | False |
WildernessMapProvider.is_valid_coordinates | (self, wilderness, coordinates) | Returns True if coordinates is valid and can be walked to.
Args:
wilderness: the wilderness script
coordinates (tuple): the coordinates to check as (x, y) tuple.
Returns:
bool: True if the coordinates are valid
| Returns True if coordinates is valid and can be walked to. | def is_valid_coordinates(self, wilderness, coordinates):
"""Returns True if coordinates is valid and can be walked to.
Args:
wilderness: the wilderness script
coordinates (tuple): the coordinates to check as (x, y) tuple.
Returns:
bool: True if the coordinates are valid
"""
x, y = coordinates
if x < 0:
return False
if y < 0:
return False
return True | [
"def",
"is_valid_coordinates",
"(",
"self",
",",
"wilderness",
",",
"coordinates",
")",
":",
"x",
",",
"y",
"=",
"coordinates",
"if",
"x",
"<",
"0",
":",
"return",
"False",
"if",
"y",
"<",
"0",
":",
"return",
"False",
"return",
"True"
] | [
724,
4
] | [
740,
19
] | python | en | ['en', 'en', 'en'] | True |
WildernessMapProvider.get_location_name | (self, coordinates) |
Returns a name for the position at coordinates.
Args:
coordinates (tuple): the coordinates as (x, y) tuple.
Returns:
name (str)
|
Returns a name for the position at coordinates. | def get_location_name(self, coordinates):
"""
Returns a name for the position at coordinates.
Args:
coordinates (tuple): the coordinates as (x, y) tuple.
Returns:
name (str)
"""
return "The wilderness" | [
"def",
"get_location_name",
"(",
"self",
",",
"coordinates",
")",
":",
"return",
"\"The wilderness\""
] | [
742,
4
] | [
752,
31
] | python | en | ['en', 'error', 'th'] | False |
WildernessMapProvider.at_prepare_room | (self, coordinates, caller, room) |
Called when a room gets activated for certain coordinates. This happens
after every object is moved in it.
This can be used to set a custom room desc for instance or run other
customisations on the room.
Args:
coordinates (tuple): the coordinates as (x, y) where room is
located at
caller (Object): the object that moved into this room
room (WildernessRoom): the room object that will be used at that
wilderness location
Example:
An example use of this would to plug in a randomizer to show different
descriptions for different coordinates, or place a treasure at a special
coordinate.
|
Called when a room gets activated for certain coordinates. This happens
after every object is moved in it.
This can be used to set a custom room desc for instance or run other
customisations on the room. | def at_prepare_room(self, coordinates, caller, room):
"""
Called when a room gets activated for certain coordinates. This happens
after every object is moved in it.
This can be used to set a custom room desc for instance or run other
customisations on the room.
Args:
coordinates (tuple): the coordinates as (x, y) where room is
located at
caller (Object): the object that moved into this room
room (WildernessRoom): the room object that will be used at that
wilderness location
Example:
An example use of this would to plug in a randomizer to show different
descriptions for different coordinates, or place a treasure at a special
coordinate.
"""
pass | [
"def",
"at_prepare_room",
"(",
"self",
",",
"coordinates",
",",
"caller",
",",
"room",
")",
":",
"pass"
] | [
754,
4
] | [
772,
12
] | python | en | ['en', 'error', 'th'] | False |
Funnelarea.aspectratio | (self) |
Sets the ratio between height and width
The 'aspectratio' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
|
Sets the ratio between height and width
The 'aspectratio' property is a number and may be specified as:
- An int or float in the interval [0, inf] | def aspectratio(self):
"""
Sets the ratio between height and width
The 'aspectratio' property is a number and may be specified as:
- An int or float in the interval [0, inf]
Returns
-------
int|float
"""
return self["aspectratio"] | [
"def",
"aspectratio",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"aspectratio\"",
"]"
] | [
59,
4
] | [
70,
34
] | python | en | ['en', 'error', 'th'] | False |
Funnelarea.baseratio | (self) |
Sets the ratio between bottom length and maximum top length.
The 'baseratio' property is a number and may be specified as:
- An int or float in the interval [0, 1]
Returns
-------
int|float
|
Sets the ratio between bottom length and maximum top length.
The 'baseratio' property is a number and may be specified as:
- An int or float in the interval [0, 1] | def baseratio(self):
"""
Sets the ratio between bottom length and maximum top length.
The 'baseratio' property is a number and may be specified as:
- An int or float in the interval [0, 1]
Returns
-------
int|float
"""
return self["baseratio"] | [
"def",
"baseratio",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"baseratio\"",
"]"
] | [
79,
4
] | [
90,
32
] | python | en | ['en', 'error', 'th'] | False |
Funnelarea.customdata | (self) |
Assigns extra data each datum. This may be useful when
listening to hover, click and selection events. Note that,
"scatter" traces also appends customdata items in the markers
DOM elements
The 'customdata' property is an array that may be specified as a tuple,
list, numpy array, or pandas Series
Returns
-------
numpy.ndarray
|
Assigns extra data each datum. This may be useful when
listening to hover, click and selection events. Note that,
"scatter" traces also appends customdata items in the markers
DOM elements
The 'customdata' property is an array that may be specified as a tuple,
list, numpy array, or pandas Series | def customdata(self):
"""
Assigns extra data each datum. This may be useful when
listening to hover, click and selection events. Note that,
"scatter" traces also appends customdata items in the markers
DOM elements
The 'customdata' property is an array that may be specified as a tuple,
list, numpy array, or pandas Series
Returns
-------
numpy.ndarray
"""
return self["customdata"] | [
"def",
"customdata",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"customdata\"",
"]"
] | [
99,
4
] | [
113,
33
] | python | en | ['en', 'error', 'th'] | False |
Funnelarea.customdatasrc | (self) |
Sets the source reference on Chart Studio Cloud for customdata
.
The 'customdatasrc' property must be specified as a string or
as a plotly.grid_objs.Column object
Returns
-------
str
|
Sets the source reference on Chart Studio Cloud for customdata
.
The 'customdatasrc' property must be specified as a string or
as a plotly.grid_objs.Column object | def customdatasrc(self):
"""
Sets the source reference on Chart Studio Cloud for customdata
.
The 'customdatasrc' property must be specified as a string or
as a plotly.grid_objs.Column object
Returns
-------
str
"""
return self["customdatasrc"] | [
"def",
"customdatasrc",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"customdatasrc\"",
"]"
] | [
122,
4
] | [
134,
36
] | python | en | ['en', 'error', 'th'] | False |
Funnelarea.dlabel | (self) |
Sets the label step. See `label0` for more info.
The 'dlabel' property is a number and may be specified as:
- An int or float
Returns
-------
int|float
|
Sets the label step. See `label0` for more info.
The 'dlabel' property is a number and may be specified as:
- An int or float | def dlabel(self):
"""
Sets the label step. See `label0` for more info.
The 'dlabel' property is a number and may be specified as:
- An int or float
Returns
-------
int|float
"""
return self["dlabel"] | [
"def",
"dlabel",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"dlabel\"",
"]"
] | [
143,
4
] | [
154,
29
] | python | en | ['en', 'error', 'th'] | False |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.