source: WorldVistAEHR/trunk/r/ONCOLOGY-ONC/ONCOST.m@ 1259

Last change on this file since 1259 was 613, checked in by George Lilly, 15 years ago

initial load of WorldVistAEHR

File size: 1.5 KB
Line 
1ONCOST ;Hines OIFO - STATISTICS TIME FRAME TASKS ;9/28/93 08:52
2 ;;2.11;ONCOLOGY;**1,5,23,44**;Mar 07, 1995
3 ;
4 ;Called from ONCOSC
5 ;out: ONCOS("YR") OR Y="^" (exit)
6ACT ;ANNUAL CROSS TABS
7 W @IOF,!!!?10,"CROSS-TABS for ANNUAL Reports - requires",!?10,"definition of TIME-FRAME (year/range)",!!!
8 ;
9TF ;Select time frame for statistical routines; callable entry point
10 K DIR S DIR("A")=" Select time frame",DIR(0)="SO^1:All years;2:Range of years;3:Particular year" D ^DIR K DIR Q:$D(DIRUT)
11Y ;Entry point for determining begining and ending year of Registry
12 S TF=Y,BYR=$O(^ONCO(165.5,"AY",0)),BEG=$E(DT,1)+17_$E(DT,2,3) F YR=BEG-1:-1:BYR-1 S EYR=$O(^ONCO(165.5,"AY",YR)) Q:EYR'=""
13 ;
14DIR ;Three pathways: Al=All years, RG=Range, AN=one year
15D D AL:TF=1,RG:TF=2,AN:TF=3 Q:Y[U!(Y="")
16 I $D(ONCOT) S ONCOS("AF")=1
17 K DIR,BYR,EYR,TF,Y1,Y2,YR Q
18AL ;All years
19 S ONCOS("YR")="ALL"
20 Q
21RG ;RANGE OF YEARS FOR SEARCH
22 W !!!?10,"Select range of years (from year to year)",!?10,"from which to SEARCH DATA for study",!!
23ST K DIR S DIR(0)="LO^"_BYR_":"_EYR,DIR("A")=" Select Range years" D ^DIR Q:$D(DIRUT) G ST:Y["." S LY=$L(Y,","),Y1=$P(Y,","),Y2=$P(Y,",",LY-1)
24 ;TASK RANGE
25 W !!?25,"RANGE is "_Y1_" to "_Y2,!! K DIR S DIR("A")=" Range OK",DIR(0)="Y",DIR("B")="Y" D ^DIR Q:$D(DIRUT) G ST:Y=0 S ONCOS("YR")=Y1_U_Y2
26 Q
27 ;
28AN ;Select ACCESSION YEAR range
29 W !!
30 S YR=$E(DT,1)+17_$E(DT,2,3)
31 K DIR
32 S DIR("A")=" Select ACCESSION YEAR"
33 S DIR("B")=$S(YR=BYR:YR,1:YR-1)
34 S DIR(0)="NO^"_BYR_":"_EYR
35 D ^DIR Q:$D(DIRUT)
36 G AN:Y>YR,AN:Y'?1.N S ONCOS("YR")=Y_U_Y
37 Q
38 ;
39EX ;Exit
40 Q
Note: See TracBrowser for help on using the repository browser.