0
可以使用tickformat將格式添加到xaxis和yaxis ticks中嗎?使用tickformat格式化座標軸上的文本
的想法是切軸長名稱爲:
axiswithaverylongname --> axisw...
在plotly API參考有和例如格式化日期 https://plot.ly/javascript/reference/#layout-xaxis-tickformat
而且它們指的是D3的文件 https://github.com/d3/d3-format/blob/master/README.md
來自標準參考:
tickformat (string)
default: ""
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-format/blob/master/README.md#locale_format
And for dates see: https://github.com/d3/d3-time-
format/blob/master/README.md#locale_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"
的偉大工程!,是超級乾淨! – ueke