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 on April 23, and its replacement, is already up and running.

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

st: -local- problem

From   saqlain raza <>
To   Stata <>
Subject   st: -local- problem
Date   Wed, 16 Nov 2011 06:37:45 -0800 (PST)

Hello colleagues, I am in try to make a -local- with the following command:

local m=r(mean)
local sd=r(sd)

Then I try to generate a variable. 

gen affiloui2=(affiloui - 'm')/'sd'

but it gives me an error 

'm' invalid name

I have tried with double quotes but even then it is not working. How this problem can be solved? Is there any problem in making -local-? Note that affiloui is already a variable in the database.

Saqlain RAZA
PhD Student (

*   For searches and help try:

© Copyright 1996–2015 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index