Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down at the end of May, and its replacement, statalist.org is already up and running.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: No observations


From   Nick Cox <njcoxstata@gmail.com>
To   statalist@hsphsun2.harvard.edu
Subject   Re: st: No observations
Date   Thu, 20 Sep 2012 10:46:26 +0100

The error messages you have received tell you what is going on. -y- is
a string variable. If it is really numeric,

. destring y, replace

or failing that

. encode y, gen(Y)

will work. Otherwise,

. tab y

to see what you have.

Nick

On Thu, Sep 20, 2012 at 10:38 AM, Shittu, Aminu <ameen_vet@yahoo.com> wrote:

> I am trying to run a univariable logistic regression using
>
> -logistic x y-
>
> and the response was "no observations." Could anyone help sort this one out? Furthermore, I am not sure if I am doing it right with
>
> -logistic x i.y-
>
> which says "may not use time-series operators on string variables."
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   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   |   Site index