⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 twoway_rspike.hlp

📁 是一个经济学管理应用软件 很难找的 但是经济学学生又必须用到
💻 HLP
字号:
{smcl}
{* 08apr2005}{...}
{cmd:help twoway rspike}{right:dialogs:  {dialog twoway_overlay:overlaid twoway}{space 0}}
	{right:{dialog twoway_simple:single twoway}{space 2}}
{hline}

{title:Title}

{p2colset 5 32 34 2}{...}
{p2col :{hi:[G] graph twoway rspike} {hline 2}}Range plot with spikes{p_end}
{p2colreset}{...}


{title:Syntax}

{p 8 60 2}
{cmdab:tw:oway}
{cmd:rspike}
{it:y1var} {it:y2var} {it:xvar}
{ifin}
[{cmd:,}
{it:options}]

{p2colset 9 32 34 2}{...}
	{it:options}{col 39}description
{p2line}
	{cmdab:vert:ical}{...}
{col 32}vertical spikes; the default
	{cmdab:hor:izontal}{...}
{col 32}horizontal spikes

INCLUDE help gr_blspike2

INCLUDE help gr_axlnk

INCLUDE help gr_twopt
{p2line}
{pin}
All explicit options are {it:rightmost}, except {cmd:vertical}
and {cmd:horizontal}, which are {it:unique}; see {help repeated options}.


{title:Description}

{pstd}
A range plot has two {it:y} variables, such as high and low daily stock
price or upper and lower 95% confidence limits.

{pstd}
{cmd:twoway} {cmd:rspike} plots a range using spikes to connect the high and
low values.

{pstd}
Also see {helpb twoway spike} for another style of spike chart.


{title:Options}

{phang}
{cmd:vertical}
and
{cmd:horizontal}
    specify whether the high and low {it:y} values are to be presented
    vertically (the default) or horizontally.

{pmore}
    In the default {cmd:vertical} case, {it:y1var} and {it:y2var} record the
    minimum and maximum (or maximum and minimum) {it:y} values to be
    graphed against each {it:xvar} value.

{pmore}
    If {cmd:horizontal} is specified, the values recorded in {it:y1var} and
    {it:y2var} are plotted in the {it:x} direction and {it:xvar} is treated
    as the {it:y} value.

INCLUDE help gr_blspikef2

INCLUDE help gr_axlnkf

INCLUDE help gr_twoptf


{title:Remarks}

{pstd}
Remarks are presented under the headings

        {help twoway_rspike##remarks1:Typical use}
        {help twoway_rspike##remarks2:Advanced use}
        {help twoway_rspike##remarks3:Advanced use 2}


{marker remarks1}{...}
{title:Typical use}

{pstd}
We have daily data recording the values for the S&P 500 in 2001:

	{cmd:. sysuse sp500, clear}

	{cmd:. list date high low close in 1/5}
	{txt}
	     {c TLC}{hline 11}{c -}{hline 9}{c -}{hline 9}{c -}{hline 9}{c TRC}
	     {c |} {res}     date      high       low     close {txt}{c |}
	     {c LT}{hline 11}{c -}{hline 9}{c -}{hline 9}{c -}{hline 9}{c RT}
	  1. {c |} {res}02jan2001   1320.28   1276.05   1283.27 {txt}{c |}
	  2. {c |} {res}03jan2001   1347.76   1274.62   1347.56 {txt}{c |}
	  3. {c |} {res}04jan2001   1350.24   1329.14   1333.34 {txt}{c |}
	  4. {c |} {res}05jan2001   1334.77   1294.95   1298.35 {txt}{c |}
	  5. {c |} {res}08jan2001   1298.35   1276.29   1295.86 {txt}{c |}
	     {c BLC}{hline 11}{c -}{hline 9}{c -}{hline 9}{c -}{hline 9}{c BRC}{txt}

{pstd}
We will use the first 57 observations from these data:

	{cmd:. twoway rspike high low date in 1/57}
	  {it:({stata "gr_example sp500: twoway rspike high low date in 1/57":click to run})}
{* graph gtrspike1}{...}


{marker remarks2}{...}
{title:Advanced use}

{pstd}
{cmd:twoway} {cmd:rspike} can be usefully combined
with other {cmd:twoway} plottypes:

	{cmd}. twoway rspike high low date, lcolor(gs11) ||
		 line close date || in 1/57{txt}
	  {it:({stata "gr_example sp500: twoway rspike high low date, lcolor(gs11) || line close date || in 1/57":click to run})}
{* graph gtrspike2}{...}

{pstd}
We specified {cmd:lcolor(gs11)} to tone down the spikes and give the
line plot more prominence.


{marker remarks3}{...}
{title:Advanced use 2}

{pstd}
A popular financial graph is

	{cmd}. sysuse sp500, clear

	. replace volume = volume/1000

	. twoway
		rspike hi low date ||
		line   close  date ||
		bar    volume date, barw(.25) yaxis(2) ||
	  in 1/57
	  , ysca(axis(1) r(900 1400))
	    ysca(axis(2) r(  9   45))
	    ylab(, axis(2) grid)
	    ytitle("                          Price -- High, Low, Close")
	    ytitle(" Volume (millions)", axis(2) bexpand just(left))
	    legend(off)
	    subtitle("S&P 500", margin(b+2.5))
	    note("Source:  Yahoo!Finance and Commodity Systems, Inc."){txt}
	  {it:({stata "gr_example2 tworspike":click to run})}
{* graph tworspike}{...}


{title:Also see}

{psee}
Manual:  {bf:[G] graph twoway rspike}

{psee}
Online:  
{helpb twoway spike};
{helpb twoway rarea},
{helpb twoway rbar},
{helpb twoway rcap},
{helpb twoway rcapsym},
{helpb twoway rline},
{helpb twoway rconnected},
{helpb twoway rscatter}
{p_end}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -