ONCOSSAT ;HInes OIFO/GWB - BEGIN SURVIVAL ANALYSIS ;9/30/93
;;2.2;ONCOLOGY;**1**;Jul 31, 2013;Build 8
;
IN ;CALL SURVIAL ROUTINES
G ^ONCOSSA
;
SEX ;for reference only - NOT an Option entry point
K ONCOS
S ONCOS("F")="PRIMARY",ONCOS("T")="ALL"
S ONCOS("D")="SURVIVAL MONTHS^M^Y"
S ONCOS("S")="STATUS=""Dead""",ONCOS("G")="2"
S ONCOS("G",1)=".1^Males^VAL(.1)=""Male"""
S ONCOS("T")="ONCO-ANALYTIC"
S ONCOS("G",2)=".1^Females^VAL(.1)=""Female"""
S ONCOS("L")="PY" G DEV
;
;
STG ;SURVIVAL BY STAGE GROUPS
K ONSOS D OV G EX:Y<0 S ONCOS("G")=4,ONCOS("G",1)="38.5^Stage I^VAL(38.5)=""I""",ONCOS("G",2)="38.5^Stage II^VAL(38.5)=""II""",ONCOS("G",3)="38.5^Stage III^VAL(38.5)=""III""",ONCOS("G",4)="38.5^Stage IV^VAL(38.5)=""IV""" G DEV
K ONCOS D OV S ONCOS("G")="1",ONCOS("G",1)=".01^Prostate^VAL(.01)=""PROSTATE""" G DEV
;
TX ;SURVIVAL BY TREATMENT
K ONCOS D OV G EX:Y<0
S ONCOS("G")=9
S ONCOS("G",1)="43^Surgery of primary site^VAL(43)=""SUR"""
S ONCOS("G",2)="43^Radiation^VAL(43)=""XRT"""
S ONCOS("G",3)="43^Chemotherapy^VAL(43)=""CMX"""
S ONCOS("G",4)="43^Hormone therapy^VAL(43)=""HOR"""
S ONCOS("G",5)="43^Immunotherapy^VAL(43)=""BRM"""
S ONCOS("G",6)="43^Hema Trans/Endocrine Proc^VAL(43)=""HEM"""
S ONCOS("G",7)="43^Other treatment^VAL(43)=""OTR"""
S ONCOS("G",8)="43^Combination treatment^($L(VAL(43))>3)&(VAL(43)'=""NONE"")"
S ONCOS("G",9)="43^No treatment^(VAL(43)=""NTX"")!(VAL(43)=""NONE"")"
G DEV
;
SP ;SURVIVAL BY SITE/(use Sex to get one curve)
W !!!,"Enter a package template name (beginning with ONCO) or your own"
W !,"template name below.",!
W !,"Search template names begin with ONCOS. All other ONCO templates"
W !,"are sort templates.",!
W !,"If you select a sort template here, you will be prompted for a"
W !,"search template later.",!
K ONCOS D OV G EX:Y<0 S ONCOS("G")=1,ONCOS("G",1)=".1^VAL(.1)=""Male""",ONCOS("G",2)=".1^Females^VAL(.1)=""Female""" G DEV
;
DEV ;DEVICE SELECTION & TASKING
D ^ONCOSSA G EX
ZIS K IO("Q") S %ZIS="Q" S:$D(ONCOS("I")) IOP=ONCOS("I") D ^%ZIS I POP S ONCOUT="" G EX
NQ I '$D(IO("Q")) D ^ONCOSSA G EX
S ZTRTN="PRINT^ONCOSSA",ZTDESC="ONCOLOGY SURVIVAL"
S ZTSAVE("ONCOS*")="" D ^%ZTLOAD K ZTSK G EX
ZT S ZTRTN="PRINT^ONCOSSA",ZTDESC="ONCOLOGY SURVIVAL",ZTSAVE("ONCOS*")="" D ^%ZTLOAD K ZTSK G EX
;
OV S ONCOS("FI")="165.5^ONCOLOGY PRIMARY^ONCO(165.5,",ONCOS("D")="SURVIVAL MONTHS^M^Y",ONCOS("L")="PY",ONCOS("S")="STATUS=""Dead"""
S DIC="^DIBT(",DIC("A")=" Select Template: ",DIC(0)="AEZ" D ^DIC Q:Y<0 S ONCOS("T")=$P(Y,U,2) W ONCOS("T")
W !!,?5,"REMINDER: Run Define Search Criteria option",!
W ?5,"to be sure selected entries are up-to-date!!",!!
S DIR("A")="Continue ",DIR("B")="Y",DIR(0)="Y" D ^DIR G EX:Y'=1
Q
;
EX ;Exit routine
K IOP,DIC,ONCOEX,ONCOS,%DT,%ZISOS,GIL,INT,%K,%T,FIL,T,TX D ^%ZISC Q
K FNAM,GBL,HLAB,OT,W,ROWDEF
Q
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HONCOSSAT 2897 printed Dec 13, 2024@02:25:46 Page 2
ONCOSSAT ;HInes OIFO/GWB - BEGIN SURVIVAL ANALYSIS ;9/30/93
+1 ;;2.2;ONCOLOGY;**1**;Jul 31, 2013;Build 8
+2 ;
IN ;CALL SURVIAL ROUTINES
+1 GOTO ^ONCOSSA
+2 ;
SEX ;for reference only - NOT an Option entry point
+1 KILL ONCOS
+2 SET ONCOS("F")="PRIMARY"
SET ONCOS("T")="ALL"
+3 SET ONCOS("D")="SURVIVAL MONTHS^M^Y"
+4 SET ONCOS("S")="STATUS=""Dead"""
SET ONCOS("G")="2"
+5 SET ONCOS("G",1)=".1^Males^VAL(.1)=""Male"""
+6 SET ONCOS("T")="ONCO-ANALYTIC"
+7 SET ONCOS("G",2)=".1^Females^VAL(.1)=""Female"""
+8 SET ONCOS("L")="PY"
GOTO DEV
+9 ;
+10 ;
STG ;SURVIVAL BY STAGE GROUPS
+1 KILL ONSOS
DO OV
if Y<0
GOTO EX
SET ONCOS("G")=4
SET ONCOS("G",1)="38.5^Stage I^VAL(38.5)=""I"""
SET ONCOS("G",2)="38.5^Stage II^VAL(38.5)=""II"""
SET ONCOS("G",3)="38.5^Stage III^VAL(38.5)=""III"""
SET ONCOS("G",4)="38.5^Stage IV^VAL(38.5)=""IV"""
GOTO DEV
+2 KILL ONCOS
DO OV
SET ONCOS("G")="1"
SET ONCOS("G",1)=".01^Prostate^VAL(.01)=""PROSTATE"""
GOTO DEV
+3 ;
TX ;SURVIVAL BY TREATMENT
+1 KILL ONCOS
DO OV
if Y<0
GOTO EX
+2 SET ONCOS("G")=9
+3 SET ONCOS("G",1)="43^Surgery of primary site^VAL(43)=""SUR"""
+4 SET ONCOS("G",2)="43^Radiation^VAL(43)=""XRT"""
+5 SET ONCOS("G",3)="43^Chemotherapy^VAL(43)=""CMX"""
+6 SET ONCOS("G",4)="43^Hormone therapy^VAL(43)=""HOR"""
+7 SET ONCOS("G",5)="43^Immunotherapy^VAL(43)=""BRM"""
+8 SET ONCOS("G",6)="43^Hema Trans/Endocrine Proc^VAL(43)=""HEM"""
+9 SET ONCOS("G",7)="43^Other treatment^VAL(43)=""OTR"""
+10 SET ONCOS("G",8)="43^Combination treatment^($L(VAL(43))>3)&(VAL(43)'=""NONE"")"
+11 SET ONCOS("G",9)="43^No treatment^(VAL(43)=""NTX"")!(VAL(43)=""NONE"")"
+12 GOTO DEV
+13 ;
SP ;SURVIVAL BY SITE/(use Sex to get one curve)
+1 WRITE !!!,"Enter a package template name (beginning with ONCO) or your own"
+2 WRITE !,"template name below.",!
+3 WRITE !,"Search template names begin with ONCOS. All other ONCO templates"
+4 WRITE !,"are sort templates.",!
+5 WRITE !,"If you select a sort template here, you will be prompted for a"
+6 WRITE !,"search template later.",!
+7 KILL ONCOS
DO OV
if Y<0
GOTO EX
SET ONCOS("G")=1
SET ONCOS("G",1)=".1^VAL(.1)=""Male"""
SET ONCOS("G",2)=".1^Females^VAL(.1)=""Female"""
GOTO DEV
+8 ;
DEV ;DEVICE SELECTION & TASKING
+1 DO ^ONCOSSA
GOTO EX
ZIS KILL IO("Q")
SET %ZIS="Q"
if $DATA(ONCOS("I"))
SET IOP=ONCOS("I")
DO ^%ZIS
IF POP
SET ONCOUT=""
GOTO EX
NQ IF '$DATA(IO("Q"))
DO ^ONCOSSA
GOTO EX
+1 SET ZTRTN="PRINT^ONCOSSA"
SET ZTDESC="ONCOLOGY SURVIVAL"
+2 SET ZTSAVE("ONCOS*")=""
DO ^%ZTLOAD
KILL ZTSK
GOTO EX
ZT SET ZTRTN="PRINT^ONCOSSA"
SET ZTDESC="ONCOLOGY SURVIVAL"
SET ZTSAVE("ONCOS*")=""
DO ^%ZTLOAD
KILL ZTSK
GOTO EX
+1 ;
OV SET ONCOS("FI")="165.5^ONCOLOGY PRIMARY^ONCO(165.5,"
SET ONCOS("D")="SURVIVAL MONTHS^M^Y"
SET ONCOS("L")="PY"
SET ONCOS("S")="STATUS=""Dead"""
+1 SET DIC="^DIBT("
SET DIC("A")=" Select Template: "
SET DIC(0)="AEZ"
DO ^DIC
if Y<0
QUIT
SET ONCOS("T")=$PIECE(Y,U,2)
WRITE ONCOS("T")
+2 WRITE !!,?5,"REMINDER: Run Define Search Criteria option",!
+3 WRITE ?5,"to be sure selected entries are up-to-date!!",!!
+4 SET DIR("A")="Continue "
SET DIR("B")="Y"
SET DIR(0)="Y"
DO ^DIR
if Y'=1
GOTO EX
+5 QUIT
+6 ;
EX ;Exit routine
+1 KILL IOP,DIC,ONCOEX,ONCOS,%DT,%ZISOS,GIL,INT,%K,%T,FIL,T,TX
DO ^%ZISC
QUIT
+2 KILL FNAM,GBL,HLAB,OT,W,ROWDEF
+3 QUIT