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

st: -strel- syntax problems...

From   Neil Shephard <[email protected]>
To   [email protected]
Subject   st: -strel- syntax problems...
Date   Mon, 06 Oct 2008 17:31:56 +0100


This is a bit of a long shot, but I'm stumped at the moment and need to
make some headway soon.  If anyone has experience using -strel- any
insights you can offer would be appreciated.

I'm trying to use the -strel- command written by authors at the Cancer
Survival Group at the London School of Hygeine a& Tropical Medicine (see ).  I'm
slightly handicapped though as despite contacting the authors last I'm
yet to hear back from them and am working with the ado-files left by a
colleague who downloaded them.  Unfortunately they only seem to have
updated the most recent ado-file and not the associated help file so I
don't have a help file for the version I'm using :-\

To use the command data should be -stset- prior to running and the old
help file specifically states...

"Before using strel, the command stset is required to inform Stata of the
key survival-time variables (see stset helpfile).  Survival time must
be declared indirectly by declaring age at entry or origin and age at
exit. A survival time calculated by the user may be present in the dataset
but must not be declared in stset (and therefore takes no part in the

Now assuming this hasn't changed between versions (and apologies if I've
made an ass out of u and me)  I have -stset- my data as per these
instructions.  I have the following variables which I -stset-

. des death age_death age

              storage  display     value
variable name   type   format      label      variable label
death           byte   %9.0g       death      Binary indicator showing
who died
age_death       float  %9.0g                  Age at Death (in years)
age             float  %9.0g                  Age at Diagnosis (in years)

. stset age_death, failure(death) origin(age)

     failure event:  death != 0 & death < .
obs. time interval:  (origin, age_death]
 exit on or before:  failure
    t for analysis:  (time-origin)
            origin:  time age

   244729  total obs.
        1  obs. end on or before enter()
   244728  obs. remaining, representing
        0  failures in single record/single failure data
 608297.2  total analysis time at risk, at risk from t =         0
                             earliest observed entry t =         0
                                  last observed exit t =  12.53388

. st_show

         failure _d:  death
   analysis time _t:  (age_death-origin)
             origin:  time age

I have my life tables set-up in a separate file and am trying to run
-strel- but can not get past the syntax....

. set trace on
. strel br(0[0.25]3[.5]5) using(data/stata/life_tables) if(sex == 1), 
mergeby(sex year age)
begin strel ---
- version 8.2
- if replay() {
  syntax [, *]
  if _by() {
  error 190
  if "`e(cmd2)'" != "strel" {
  error 301
  ml display, `options'
- syntax anything(name=breaks id="numlist") using/ [if] [in] [iweight/],
[ Mergeby(varlist) SHowrates at(numlist asc >=0
> ) GRoup(integer 0) TRy(integer 3) Continue DIagdate(varname numeric)
PERiod(numlist asc >1900 <2050 min=1 max=2 intege
> r) HYbrid STANdardise(varlist min=1) STDprop(namelist min=1 max=1)
BRenner SAving(string) replace level(integer 0) FIN
> al DIVider SEParator(integer 0) noMODel * ]
invalid 'data'
end strel ---

I can't fathom where the "invalid 'data'" is coming from based on the
syntax definintion?  There doesn't appear to be any checks made on the
data itself, simply that either breaks or a numlist are supplied along
with the 'using lifetables'.

Like I say, its a long shot but if anyone has experience of using
-strel- and has any suggestions I'd be very grateful.



"We should make things as simple as possible, but not simpler" - Anon (not Albert Einstein)

This  message  may  contain  confidential and  privileged  information.
If you  are not the  intended recipient  you should not  disclose, copy
or distribute information in this e-mail or take any action in reliance
on its contents.  To do so is strictly  prohibited and may be unlawful.
Please  inform  the  sender that  this  message has  gone astray before
deleting it.  Thank you.

2008 marks the 60th anniversary of the NHS.  It's an opportunity to pay
tribute to the NHS staff and volunteers who help shape the service, and
celebrate their achievements.

If you work for the NHS  and  would like  an NHSmail  email account, go

*   For searches and help try:

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