📄 expandcl.hlp
字号:
{smcl}
{* 24nov2004}{...}
{cmd:help expandcl}{right:dialog: {bf:{dialog expandcl}}}
{hline}
{title:Title}
{p2colset 5 21 23 2}{...}
{p2col :{hi:[D] expandcl} {hline 2}}Duplicate clustered observations{p_end}
{p2colreset}{...}
{title:Syntax}
{p 8 18 2}
{cmd:expandcl} [=]{it:{help exp}} {ifin} {cmd:,} {opth cl:uster(varlist)}
{opth gen:erate(newvar)}
{title:Description}
{pstd}
{cmd:expandcl} duplicates clusters of observations and generates a new
variable that identifies the clusters uniquely.
{pstd}
{cmd:expandcl} replaces each cluster in the current dataset with n
copies of the cluster, where n is equal to the integer part of the
required expression. The expression is required to be constant within
cluster. If the expression is less than 1 or equal to {it:missing}, it is
interpreted as if it were 1, and the cluster is retained but not duplicated.
{title:Options}
{phang}
{opth cluster(varlist)} is required and specifies the variables that identify
the clusters before expanding the data.
{phang}
{opth generate(newvar)} is required and stores unique identifiers for the
duplicated clusters in {it:newvar}. {it:newvar} will identify the clusters
using consecutive integers starting from 1.
{title:Examples}
{phang}{cmd:. expandcl n, generate(newcl) cluster(cl)}
{phang}{cmd:. sort newcl cl x}
{phang}{cmd:. list, sep(0)}
{title:Also see}
{psee}
Manual: {hi:[D] expandcl}
{psee}
Online: {bf:{help bsample}}, {bf:{help expand}}
{p_end}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -