Statalist The Stata Listserver


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

st: general varlist in programs


From   Kyle Hood <kyle.hood@yale.edu>
To   statalist@hsphsun2.harvard.edu
Subject   st: general varlist in programs
Date   Mon, 21 May 2007 15:12:31 -0400 (EDT)

I am using Stata v.8, and I want to write a program like

program progname
syntax varlist
...
end

Where I can call it in a statement like

progname y x* z*

When I try to do so, it gives me an error "* invalid name".

In the overall program that I am writing, I need to input different numbers of x and z variables, so it's not feasible for me to type them all out in the program call.

This must be a simple fix, but I just can't find the solution in the help files. Does anyone know what to do?

Kyle
*
* 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