Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: Re: scalar properties


From   "Michael Blasnik" <michael.blasnik@verizon.net>
To   <statalist@hsphsun2.harvard.edu>
Subject   st: Re: scalar properties
Date   Fri, 19 Aug 2005 20:50:38 -0400

----- Original Message ----- From: <Richard_Lenhardt@rush.edu>
Subject: st: scalar properties



I'd like to tablulate hospital specific kappas, in which a 10 item
questionnaire was completed by two observers and with dicotomous responses
to the items.   I wrote a do file defining the scalars:

kap item1obs1 item1obs2 if hosp==2
scalar   item1 = r(kappa)
display item1

and so on.

This displays the kappa of item 1 hospital 2 but I am not able to tabulate
this or manupulate it algebraically.

When I search for the the newly defined variable item1, I get an error
message that the variable cannot be found.  It seems that it has something
to do with scalars.  I've checked the manuals and can't figure it out.

Thank you,
Richard Lenhardt
your item1 isn't a variable, it's a scalar. The scalar can be manipulated algebraically and displayed, but it can not be used as a variable. If you really want a variable, then use -generate- to create it. Most likely, you don't want a variable that is just a constant. Perhaps you should explain what you actually want to do. If you want to record the kappa values for different values of hosp, perhaps -statsby- could help?

Michael Blasnik
michael.blasnik@verizon.net


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