📄 tickstyle.hlp
字号:
{smcl}
{* 01mar2005}{...}
{cmd:help tickstyle}
{hline}
{* index tickstyle it}{...}
{title:Title}
{p2colset 5 22 24 2}{...}
{p2col :{hi:[G] {it:tickstyle}} {hline 2}}Choices for the overall look of axis ticks and axis tick labels{p_end}
{p2colreset}{...}
{title:Syntax}
{it:tickstyle}{col 30}description
{hline 52}
{cmd:major}{...}
{col 30}major tick and major tick label
{cmd:major_nolabel}{...}
{col 30}major tick with no tick label
{cmd:major_notick}{...}
{col 30}major tick label with no tick
{cmd:minor}{...}
{col 30}minor tick and minor tick label
{cmd:minor_nolabel}{...}
{col 30}minor tick with no tick label
{cmd:minor_notick}{...}
{col 30}minor tick label with no tick
{cmd:none}{...}
{col 30}no tick, no tick label
{hline 52}
{pin}
Other {it:tickstyles} may be available; type
{cmd:.} {bf:{stata graph query tickstyle}}
{pin}
to obtain the complete list of {it:tickstyles} installed on your computer.
{title:Description}
{pstd}
Ticks are the marks that appear on axes. {it:tickstyle} specifies the
overall look of ticks. See {it:{help axis_label_options}}.
{title:Remarks}
{pstd}
Remarks are presented under the headings
{help tickstyle##remarks1:What is a tick? What is a tick label?}
{help tickstyle##remarks2:What is a tickstyle?}
{help tickstyle##remarks3:You do not need to specify a tickstyle}
{help tickstyle##remarks4:Suppressing ticks and/or tick labels}
{* index tick, definition}{...}
{marker remarks1}{...}
{title:What is a tick? What is a tick label?}
{pstd}
A tick is the small line that extends or crosses an axis and next to which,
sometimes, numbers are placed.
{pstd}
A tick label is the text (typically a number) that optionally appears beside
the tick.
{marker remarks2}{...}
{title:What is a tickstyle?}
{pstd}
{it:tickstyle} is really misnamed; it ought to be called a
{it:tick_and_tick_label_style} in that it controls both the look of ticks and
their labels.
{pstd}
Ticks are defined by three attributes:
{phang2}
1. the length of the tick;
see {it:{help relativesize}}
{phang2}
2. whether the tick extends out, in, or crosses the axis
{phang2}
3. the line style of the tick, including its thickness, color,
and whether it is to be solid, dashed, etc.;
see {it:{help linestyle}}
{pstd}
Labels are defined by two attributes:
{phang2}
1. the size of the text
{phang2}
2. the color of the text
{pstd}
Ticks and tick labels share one more attribute:
{phang2}
1. the gap between the tick and the tick label
{pstd}
The {it:tickstyle} specifies all six of these attributes.
{marker remarks3}{...}
{title:You do not need to specify a tickstyle}
{pstd}
The {it:tickstyle} is specified in the options named
{c -(}{...}
{cmd:y}|{cmd:x}{...}
{c )-}{...}
{c -(}{...}
{cmd:label}|{cmd:tick}|{cmd:mlabel}|{cmd:mtick}{...}
{c )-}{...}
{cmd:(tstyle(}{it:tickstyle}{cmd:))}
{pstd}
Correspondingly, there are other
{c -(}{cmd:y}|{cmd:x}{c )-}{c -(}{cmd:label}|{cmd:tick}|{cmd:mlabel}|{cmd:mtick}{c )-}{cmd:()}
suboptions that allow you to specify the individual attributes;
see {it:{help axis_label_options}}.
{pstd}
You specify the {it:tickstyle} when a style exists that is exactly what you
desire or when another style would allow you to specify fewer changes to
obtain what you want.
{* grid lines, without ticks}{...}
{* ticks, suppressing}{...}
{marker remarks4}{...}
{title:Suppressing ticks and/or tick labels}
{pstd}
To suppress the ticks that usually appear, specify one of these
styles
{it:tickstyle}{col 30}description
{hline 50}
{cmd:major_nolabel}{...}
{col 30}major tick with no tick label
{cmd:major_notick}{...}
{col 30}major tick label with no tick
{cmd:minor_nolabel}{...}
{col 30}minor tick with no tick label
{cmd:minor_notick}{...}
{col 30}minor tick label with no tick
{cmd:none}{...}
{col 30}no tick, no tick label
{hline 50}
{phang}
For instance, you might type
{phang2}
{cmd:. scatter} .... {cmd:, ylabel(,tstyle(major_notick))}
{pstd}
Suppressing the ticks can be useful when you are creating special effects. For
instance, consider a case where you wish to add grid lines to a graph at
{it:y} = 10, 20, 30, and 40, but you do not want ticks or labels at those
values. Moreover, you do not want even to interfere with the ordinary ticking
or labeling of the graph. The solution is
{phang2}
{cmd:. scatter} ...{cmd:, ymtick(10(10)40, grid tstyle(none))}
{pstd}
We "borrowed" the {cmd:ymtick()} option and changed it so that it did not
output ticks. We could just as well have borrowed the {cmd:ytick()} option.
See {it:{help axis_label_options}}.
{title:Also see}
{psee}
Manual: {bf:[G] {it:tickstyle}}
{psee}
Online:
{it:{help axis_label_options}}
{p_end}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -