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

📄 svyset.hlp

📁 是一个经济学管理应用软件 很难找的 但是经济学学生又必须用到
💻 HLP
字号:
{smcl}
{* 30mar2005}{...}
{cmd:help svyset}{...}
{right:dialog:  {bf:{dialog svyset}}}
{hline}

{title:Title}

{pstd}
{hi:[SVY] svyset} {hline 2} Survey data settings


{title:Syntax}

{pstd}
Single-stage syntax

{p 8 15 2}
{cmd:svyset}  [{it:psu}] {weight}
	[{cmd:,} {it:design_options} {it:options}]


{pstd}
Multiple-stage syntax

{p 8 15 2}
{cmd:svyset} {it:psu} {weight} [{cmd:,} {it:design_options}] [{cmd:||} {it:ssu}
{cmd:,} {it:design_options}] ... [{it:options}]

{pstd}
Report or clear the current settings

{p 8 15 2}
{cmd:svyset} [{cmd:,} {opt clear}]


{synoptset 26 tabbed}{...}
{synopthdr:design_options}
{synoptline}
{syntab:Main}
{synopt :{opt str:ata(varname)}}variable identifying strata{p_end}
{synopt :{opt fpc(varname)}}finite-population correction{p_end}
{synoptline}

{synopthdr:options}
{synoptline}
{syntab:Weights}
{synopt :{opt brr:weight(varlist)}}balanced
	repeated replication (BRR) weights{p_end}
{synopt :{opt jkr:weight(varlist, ...)}}jackknife replication weights{p_end}

{syntab:SE}
{synopt :{cmd:vce(}{opt linear:ized}{cmd:)}}Taylor
	linearized variance estimation{p_end}
{synopt :{cmd:vce(brr)}}balanced
	repeated replication (BRR) variance estimation{p_end}
{synopt :{cmd:vce(}{opt jack:knife}{cmd:)}}jackknife
	variance estimation{p_end}
{synopt :{opt mse}}use
	the MSE formula with {cmd:vce(brr)} or {cmd:vce(jackknife)}{p_end}

{syntab:Poststrata}
{synopt :{opt posts:trata(varname)}}variable identifying poststrata{p_end}
{synopt :{opt postw:eight(varname)}}poststratum population sizes{p_end}

{p2coldent:+ {opt noclear}}change
	some of the settings without clearing the others{p_end}
{p2coldent:+ {opt clear}}clear
	the specified settings; implies {opt noclear}{p_end}
{synoptline}
{p 4 6 2}
+ {opt noclear} and {opt clear()} are not shown in the dialog box.
{p_end}
{p 4 6 2}
{cmd:pweight}s and {cmd:iweight}s are allowed; see {help weights}.
{p_end}
{p 4 6 2}
The full specification for {opt jkrweight()} is
{p_end}
{phang2}
{opt jkr:weight}{cmd:(}{varlist}
	[{cmd:,}
		{opt str:atum}{cmd:(}{it:#} [{it:#} ...]{cmd:)}
		{opt fpc}{cmd:(}{it:#} [{it:#} ...]{cmd:)}
		{opt mult:iplier}{cmd:(}{it:#} [{it:#} ...]{cmd:)}
		{opt reset}
	]
{p_end}


{title:Description}

{pstd}
{cmd:svyset} declares the data to be complex survey data, designates variables
that contain information about the survey design, and specifies the default
method for variance estimation.  You must {cmd:svyset} your data before using
the {cmd:svy} prefix command; see {helpb svy}.

{phang}
{it:psu} is {cmd:_n} or the name of a variable (numeric or string) that
contains identifiers for the primary sampling units (clusters).  Use {cmd:_n}
to indicate that individuals (instead of clusters) were randomly sampled if
the design does not involve clustered sampling.  In the single-stage syntax,
{it:psu} is optional and defaults to {cmd:_n}.

{phang}
{it:ssu} is {cmd:_n} or the name of a variable (numeric or string) that
contains identifiers for sampling units (clusters) at the subsequent stages of
the survey design.  Use {cmd:_n} to indicate that individuals were randomly
sampled within the last sampling stage.

{pstd}
Settings made by {cmd:svyset} are saved with a dataset.  So, if a dataset is
saved after it has been {cmd:svyset}, it does not have to be set again.

{pstd}
The current settings are reported when {cmd:svyset} is called without
arguments:

	{cmd:. svyset}

{pstd}
Use the {opt clear} option to remove the current settings:

	{cmd:. svyset, clear}


{title:Options}

{dlgtab:Main}

{phang}
{opt strata(varname)} specifies the name of a variable (numeric or string)
that contains stratum identifiers.

{phang}
{opt fpc(varname)} requests a finite population correction for the variance
estimates.  If {it:varname} has values less than or equal to 1, it is
interpreted as a stratum sampling rate {it:f}_{it:h} =
{it:n}_{it:h}/{it:N}_{it:h}, where {it:n}_{it:h} = number of units sampled
from stratum {it:h} and {it:N}_{it:h} = total number of units in the
population belonging to stratum {it:h}.  If {it:varname} has values
greater than or equal to {it:n}_{it:h}, it is interpreted as containing
{it:N}_{it:h}.  It is an error for {it:varname} to have values between 1 and
{it:n}_{it:h}.

{dlgtab:Weights}

{phang}
{opt brrweight(varlist)} specifies the replicate weights to be used with
{cmd:vce(brr)}.

{phang}
{opt jkrweight(varlist, ...)} specifies the replicate weights to be used with
{cmd:vce(jackknife)}.

{pmore}
The following options set characteristics on the jackknife replicate weight
variables.
If a single value is specified, all the specified jackknife
replicate weight variables will be supplied with the same characteristic.
If multiple values are specified, each replicate weight variable will
be supplied with the respective value according to the order specified.
These options are not shown in the dialog box.

{phang2}
{opt stratum(# [# ...])} specifies an identifier for
the stratum in which the sampling weights have been adjusted.

{phang2}
{opt fpc(# [# ...])} specifies the FPC value to
be added as a characteristic of the jackknife replicate weight variables.
The values set by this suboption have the same interpretation as the
{opt fpc(varname)} option.

{phang2}
{opt multiplier(# [# ...])} specifies the value of a
jackknife multiplier to be added as a characteristic of the jackknife
replicate weight variables.

{phang2}
{opt reset} indicates that the characteristics for the replicate weight
variables may be overwritten or reset to the default, if they exist.

{dlgtab:SE}

{phang}
{opt vce(vcetype)} specifies the default method for variance estimation; see
{bf:[SVY] variance estimation}.

{phang2}
{cmd:vce(linearized)} sets the default to Taylor linearization.

{phang2}
{cmd:vce(brr)} sets the default to balanced repeated replication; also see
{helpb svy brr}.

{phang2}
{cmd:vce(jackknife)} sets the default to the jackknife;
see {helpb svy jackknife}.

{phang}
{opt mse} specifies that the MSE formula be used when {cmd:vce(brr)} or
{cmd:vce(jackknife)} is specified.  This option requires {cmd:vce(brr)} or
{cmd:vce(jackknife)}.

{dlgtab:Poststrata}

{phang}
{opt poststrata(varname)} specifies the name of the variable
(numeric or string) that contains poststratum identifiers.

{phang}
{opt postweight(varname)} specifies the name of the numeric
variable that contains poststratum population totals (or sizes),
i.e. the number of elementary sampling units in the population within each
poststratum.  These totals are assumed also to be specific to the design
strata (the stratum identifiers from the {opt strata()} option).

{pstd}
The following options are available with {cmd:svyset} but are not shown in the
dialog box:

{phang}
{opt clear} clears all the settings from the data.  Typing

{pmore2}
{cmd:. svyset, clear}

{pmore}
clears the survey design characteristics from the data in memory.  Although
this option may be specified with some of the other {cmd:svyset} options, it
is redundant since {cmd:svyset} automatically clears the previous settings
before setting new survey design characteristics.

{phang}
{opt noclear} allows some of the options in {it:options} to be changed
without clearing all the other settings.  This option is not allowed with
{it:psu}, {it:ssu}, {it:design_options}, or {opt clear}

{phang}
{opt clear(opname)} allows some of the options in {it:options} to
be cleared without clearing all the other settings.  {it:opname}
refers to an option name and may be one or more of the following:

{pmore2}
{opt w:eight}{space 2}
{opt vce}{space 2}
{opt mse}{space 2}
{opt brr:weight}{space 2}
{opt jkr:weight}{space 2}
{opt post:strata}

{pmore}
This option implies the {opt noclear} option.


{title:Examples}

{phang}
{cmd:. webuse nmihs}
{p_end}
{phang}
{cmd:. svyset [pweight=finwgt], strata(stratan)}
{p_end}

{phang}
{cmd:. save mynmihs}
{p_end}
{phang}
{cmd:. use mynmihs, clear}
{p_end}
{phang}
{cmd:. svyset}
{p_end}
{phang}
{cmd:. svy: mean birthwgt}
{p_end}

{phang}
{cmd:. use mynmihs, clear}
{p_end}
{phang}
{cmd:. generate adjwgt = 2*finwgt}
{p_end}
{phang}
{cmd:. svyset [pweight=adjwgt], noclear}
{p_end}
{phang}
{cmd:. svyset [pweight=finwgt]}
{p_end}

{phang}
{cmd:. webuse stage5a, clear}
{p_end}

{pstd}
Simple random sample design (SRS), without sampling weights
{p_end}
{phang}
{cmd:. svyset _n, fpc(popsize)}
{p_end}

{pstd}
SRS with poststratification
{p_end}
{phang}
{cmd:. svyset _n, poststrat(postid) postweight(postw)}
{p_end}

{pstd}
Stratified SRS
{p_end}
{phang}
{cmd:. svyset _n [pweight=pw], strata(strata)}
{p_end}

{pstd}
Stratified SRS, sampled without replacement
{p_end}
{phang}
{cmd:. svyset _n [pw=pw], strata(strata) fpc(fpc1)}
{p_end}

{pstd}
Stratified and clustered, sampled without replacement, sampling individuals
with replacement within PSUs
{p_end}
{phang}
{cmd:. svyset su1 [pw=pw], strata(strata) fpc(fpc1) || _n}
{p_end}

{pstd}
Clustered sampling in two stages, stratified in the first stage, sampling
without replacement in the first stage, sampling with replacement in the second
stage
{p_end}
{phang}
{cmd:. svyset su1 [pw=pw], strata(strata) fpc(fpc1) || su2}
{p_end}

{pstd}
Clustered sampling without replacement in two stages, stratified in the first
stage
{p_end}
{phang}
{cmd:. svyset su1 [pw=pw], strata(strata) fpc(fpc1) || su2, fpc(fpc2)}
{p_end}

{pstd}
Stratified two-stage design, individuals sampled in the second stage
{p_end}
{phang}
{cmd:. svyset su1 [pw=pw], strata(strata) || _n}
{p_end}

{pstd}
Clustered sampling without replacement in five stages, stratified in the first
stage, with replacement sampling of individuals within the last stage
clusters:
{p_end}
{phang}
{cmd:. svyset su1 [pw=pw], strata(strata1) fpc(fpc1)}
	{cmd:|| su2, fpc(fpc2)}
	{cmd:|| su3, fpc(fpc3)}
	{cmd:|| su4, fpc(fpc4)}
	{cmd:|| su5, fpc(fpc5)}
	{cmd:|| _n}
{p_end}

{pstd}
Clustered sampling without replacement in five stages, stratified in the first
and third stage, with replacement sampling of individuals within the last
stage clusters:
{p_end}
{phang}
{cmd:. svyset su1 [pw=pw], strata(strata) fpc(fpc1)}
	{cmd:|| su2, fpc(fpc2)}
	{cmd:|| su3, fpc(fpc3) strata(strata3)}
	{cmd:|| su4, fpc(fpc4)}
	{cmd:|| su5, fpc(fpc5)}
	{cmd:|| _n}
{p_end}


{title:Also see}

{psee}
Manual:  {hi:[SVY] svyset}

{psee}
Online:
{help survey},
{helpb svy},
{helpb svydes}
{p_end}

⌨️ 快捷键说明

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