作者热门文章
- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
在像下面这样的图表中,我想将千位分隔符更改为点“.”,但我不知道如何使用 tickformat
参数以获取它。
require(plotly)
p <- plot_ly(x=~c(2012,2013,2014,2015,2016), y=~c(1200000,975000,1420000,1175000,1360000), type='bar') %>%
layout(yaxis = list(title="Income in €", tickformat=",d", gridcolor = "#bbb"), xaxis = list(title="Year"), margin=list(l=80))
p
最佳答案
据我所知,如果你使用 tickformat
, separators
被忽略。所以你可以指定你的 tickformat
或您的 separators
.
require(plotly)
p <- plot_ly(x=~c(2012, 2013, 2014, 2015, 2016), y=~c(1200000, 975000, 1420000, 1175000, 1360000), type = 'bar') %>%
layout(separators = '.,',
yaxis = list(title='Income in Euro'))
p
关于r - 更改刻度标签中的逗号和千位分隔符,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/43436009/
我正在使用报表查看器控件 (rdlc) 生成报表。我的一列表示来自 SQL 数据库的十进制值,例如: 5199.9800 在此列的末尾,汇总了所有金额。因此,金额行以这种方式表示: =Fields!
我在这段代码中尝试用以下模式替换引号 (') 的千位分隔符 (.):###'###,## import java.text.*; public class NumberFormatTests
对于具有财务计算的网站,我尝试将包含在 HTML 输入字段中的每个数字转换为 xxx,xxx,xxx.xx 格式,其中千位分隔符为逗号,小数点为小数点。与我们从 Excel 中了解到的类似。 现在是挑
有没有一种方法可以使用字符串格式化程序将 Thousands、Millions、Billions 格式化为 123K、123M、123B 而无需更改代码以将值除以 Thousand、Million 或
我是一名优秀的程序员,十分优秀!