回答編集履歴
1
Update
answer
CHANGED
@@ -8,4 +8,24 @@
|
|
8
8
|
def _set_order_of_magnitude(self):
|
9
9
|
self.orderOfMagnitude = self._order_of_mag
|
10
10
|
```
|
11
|
-

|
11
|
+

|
12
|
+
|
13
|
+
**追記**
|
14
|
+
|
15
|
+
bsdfan 氏の回答にある「scilimitsの上限と下限に同じ数字をセットすれば、指数をその数字に固定できます」を読んで `_set_order_of_magnitude` の中身を確認してみると、、、
|
16
|
+
> **fixed scaling when lower power limit = upper <> 0.**
|
17
|
+
|
18
|
+
[matplotlib/ticker.py](https://github.com/matplotlib/matplotlib/blob/main/lib/matplotlib/ticker.py#L753)
|
19
|
+
```python
|
20
|
+
def _set_order_of_magnitude(self):
|
21
|
+
# if scientific notation is to be used, find the appropriate exponent
|
22
|
+
# if using an numerical offset, find the exponent after applying the
|
23
|
+
# offset. When lower power limit = upper <> 0, use provided exponent.
|
24
|
+
if not self._scientific:
|
25
|
+
self.orderOfMagnitude = 0
|
26
|
+
return
|
27
|
+
if self._powerlimits[0] == self._powerlimits[1] != 0:
|
28
|
+
# fixed scaling when lower power limit = upper <> 0.
|
29
|
+
self.orderOfMagnitude = self._powerlimits[0]
|
30
|
+
return
|
31
|
+
```
|