Statalist The Stata Listserver


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: combination of observations


From   n j cox <n.j.cox@durham.ac.uk>
To   statalist@hsphsun2.harvard.edu
Subject   Re: st: combination of observations
Date   Tue, 13 Feb 2007 13:24:43 +0000

You are using Stata 8.0. You, or your systems administrator,
should -update- to Stata 8.2. It is free.

-comb()- is not implemented as an .ado file. It is a Stata function,
not a command or program. All Stata functions are implemented as
part of the executable and not visible to users.

That said, I am not clear precisely what your problem is, but -tuples- on SSC, or the code therein, may help.

Nick
n.j.cox@durham.ac.uk

Nikolaos A. Patsopoulos

for n observations list by combinations of k. if we set n=4 and k=2 for the
following dataset we should get:

Dataset: var1: [1] A [2] B [3] C [4] D

AB
AC
AD
BC
BD
CD

Actually insetad of list I want to run another program but the logic is the same.

Have tried to find sth like this but the comb() function only gives the number
of combinations. Some programs I found cpr (Cox) and byvar (Royston) do
combinations for a given set of number (max=5).

Is there a way I can do this in STATA (version 8.0)?

At least does anyone knows where I can one find the ado of comb()? I look into
my STATA and ado folders but it must have a different name.
*
* For searches and help try:
* http://www.stata.com/support/faqs/res/findit.html
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/




© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index