【发布时间】:2018-02-01 13:07:47
【问题描述】:
我正在使用graph twoway scatter 并添加我自己的ylabels。
我经常有很长的标签并将它们分成多行。但是,当我想将 some 标签分成两行而不是其他行时,我遇到了问题。
当我这样做时,单行标签相对于它们的tick 标记偏离中心,好像 Stata 期望它们也有两行。
请看下面的简单说明:
sysuse auto, clear
/* This graph has one long label and one short but both are off-center
relative to their tick marks */
twoway scatter length weight, ytitle("") ylabel(220 ///
`" "This one is a very long" "label, broken up" "' 140 "This one is not", ///
ang(horizontal))
/* The order of labels on the graph *does not* appear to matter */
twoway scatter length weight, ytitle("") ylabel(180 ///
`" "This one is a very long" "label, broken up" "' 220 "This one is not", ///
ang(horizontal))
/* But the order in the command *does* appear to matter */
twoway scatter length weight, ytitle("") ylabel(220 ///
"This one is not" 140 `" "This one is a very long" "label, broken up" "', ///
ang(horizontal))
这不是一个大问题,但我已经注意到了多年并且知道我的图表为什么会这样表现会很好。
【问题讨论】:
标签: stata