Statalist The Stata Listserver


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

st: Tabcount function


From   "Urvi Shah" <urvi.shah@cancer.org.uk>
To   <statalist@hsphsun2.harvard.edu>
Subject   st: Tabcount function
Date   Mon, 3 Jul 2006 15:44:13 +0100

Dear All

I am trying to use the tabcount function to produce a summary of means and
medians for my data.

This works:

mydate is the month of recruitment 
site is the centre where patients are recruited
556 - may 06
558 - july 06

tabcount mydate site,  v1(556/558) v2(1/15) replace freq(tot_rand) zero

table site, c(sum tot_rand mean tot_rand median tot_rand )

However, I want someone else to run this as a report on a regular basis and
I want to change the value list such that it either prompts the user to
specify the maxium range for v1 or use a pre-defined value  instead of hard
coding it into the program. I know I can't use the statement below. 

tabcount mydate site,  v1(556/target_date) v2(1/15) replace freq(tot_rand)
zero

Can anyone help me on this. 

Many Thanks

Urvi


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