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

st: computing percentages

From   "mertenmj" <>
To   <>
Subject   st: computing percentages
Date   Wed, 28 Apr 2004 09:36:42 -0500

I am using the following command:

g nonmetro=hmsa_r==2

g total=hmsa_r==1 | hmsa_r==2 | hmsa_r==3

gen pnonmetro=nonmetro/total 

I want the "pnonmetro" variable to be expressed in terms of percentage, from the resulting nonmetro/total. How do I do this?


Mike Merten
*   For searches and help try:

© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index