Statalist


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

st: Re: r(198) error


From   "Nirina F" <[email protected]>
To   [email protected]
Subject   st: Re: r(198) error
Date   Fri, 7 Sep 2007 11:09:31 -0400

Hello,

Thanks for your reply but I am not sure what is still wrong.

What I basically want to do is:
1- to run the regression using the variables stored in the list of
variables LHS to be used one by one as a dependent variable and then
outreg each result in the table.

2- this another related question where:
say I have a list of RHS x1.....x12

and I want to regress y  $RHS
but I would like to see use on variable in RHS increasingly ie
reg y x1
reg y x1 x2
reg y x1 x2 x3 etc.....


Thank you very much for your help

Nirina




On 8/15/07, Kit Baum <[email protected]> wrote:
> Your expansion of the macro outfile_reg probably contains spaces plus
> the word 'and'. You probably need to use compound double quotes
> (q.v.) or use a directory without embedded spaces in its name on your
> machine.
>
>
> Kit Baum, Boston College Economics and DIW Berlin
> http://ideas.repec.org/e/pba1.html
> An Introduction to Modern Econometrics Using Stata:
> http://www.stata-press.com/books/imeus.html
>
>
> On Aug 15, 2007, at 2:33 AM, statalist-digest wrote:
>
> >
> > Could anyone let me know what is wrong with the following do. file to
> > give me an invalid 'and' r(198).
> >
> >
> > /*foreach x of varlist $LHS {;
> > local xtitle "`x' OLS"   ;
> >   local outfile_reg "$dataloc/Results/reg_`x'"  ;
> >  regress  `x' $RHS, robust;
> >     outreg using "`outfile_reg'", ctitle("`xtitle'") append;
> > };
> > */;
> >
> > invalid 'and'
> > r(198);
> > Thank you,
>
> *
> *   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/
>
*
*   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–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index