source: FOIAVistA/trunk/r/GEN_MED_OTHER-GMV/GMVHG4.m@ 1327

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

initial load of FOIAVistA 6/30/08 version

File size: 3.9 KB
Line 
1GMVHG4 ;HIOFO/YH,FT-HP LASER SF 511 GRAPH - ^TMP DATA ;11/6/01 15:08
2 ;;5.0;GEN. MED. REC. - VITALS;;Oct 31, 2002
3 ;
4 ; This routine uses the following IAs:
5 ; #10104 - ^XLFSTR calls (supported)
6 ;
7SETA ;
8 I GK="Unavailable" S GK="Unavail"
9 S (GMRSITE,GMRSITE(1),GMRSITE(2),GMRINF,GMRVJ)=""
10 I GK'="" D
11 . S GMRSITE(1)=$P($G(^TMP($J,"GMRVG",GI,GDT1,GK)),"^"),GMRVJ=$P($G(^(GK)),"^",2),GMRINF=$P($G(^(GK)),"^",4)
12 . I GMRSITE(1)'="" D SYNOARY^GMVLGQU
13 I GI="H" S ^TMP($J,"GMRK","G"_(470+GCNTD))=GK_" "_GMRSITE,^TMP($J,"GMRK","G"_(1100+GCNTD))=$S(GK>0:$J(GK*2.54,0,2),1:"") S:GK>0 GMRHT=GK*2.54/100 Q
14 I GI="PN" S ^TMP($J,"GMRK","G"_(1660+GCNTD))=GK
15 I GI="C" S ^TMP($J,"GMRK","G"_(1640+GCNTD))=GK_" "_^TMP($J,"GMRK","G"_(1640+GCNTD)) Q
16 I GI="PO2"!(GI="CVP")!(GI="CG") D Q
17 . I GI="PO2" D
18 . . S (GMRINF(1),GMRINF(2))="" I GMRINF'="" D PO2^GMVLGQU(.GMRINF)
19 . . S ^TMP($J,"GMRK","G"_(1400+GCNTD))=GK_$S(GMRVJ=1:"*",1:"")
20 . . S ^TMP($J,"GMRK","G"_(1430+GCNTD))=GMRINF(1)
21 . . S ^TMP($J,"GMRK","G"_(1450+GCNTD))=GMRINF(2)
22 . . S ^TMP($J,"GMRK","G"_(1470+GCNTD))=GMRSITE
23 . . Q
24 . I GI="CVP" D
25 . . S ^TMP($J,"GMRK","G"_(1500+GCNTD))=$S(GK>0!(GK<0):$J(GK,0,1),1:GK)_$S(GMRVJ=1:"*",1:"")
26 . . S ^TMP($J,"GMRK","G"_(1530+GCNTD))=$S(GK>0!(GK<0)!($E(GK)="0"):$J(GK/1.36,0,1),1:"")_$S(GMRVJ=1:"*",1:"")
27 . . Q
28 . I GI="CG" D
29 . . S ^TMP($J,"GMRK","G"_(1550+GCNTD))=GK_GMRSITE,^TMP($J,"GMRK","G"_(1620+GCNTD))=$S(GK>0:$J(GK/.3937,0,2),1:"")
30 . . Q
31 I GI="B",GK'="" S ^TMP($J,"GMRK","G"_(450+GCNTD))=$S($L(GMRSITE," ")>3:$P(GMRSITE," ",2,4),1:GMRSITE) S:$L(GMRSITE," ")>3 ^TMP($J,"GMRK","G"_(1640+GCNTD))=$P(GMRSITE," ")
32 I '(GI="T"!(GI="P")) D Q
33 . S ^TMP($J,"GMRK","G"_(GJ*16+GCNTD+1))=GK_$S(GMRVJ=1:"*",1:"")_$S(GI="B":"",1:GMRSITE) S:GI="W" ^TMP($J,"GMRK","G"_(1200+GCNTD))=$S(GK>0:$J(GK/2.2,0,2),1:"")
34 . I GI="W",GK>0 D
35 . . S GMRBMI="",GMRBMI(1)=GDT1,GMRBMI(2)=GK D CALBMI^GMVBMI(.GMRBMI)
36 . . S ^TMP($J,"GMRK","G"_(1300+GCNTD))=GMRBMI K GMRBMI
37 I GI="T",GK>0 S ^TMP($J,"GMRK","G"_(GJ*16+GCNTD+1))=GK-93
38 I GK'="",GI="P","UNAVAILABLEPASSREFUSED"'[$$UP^XLFSTR(GK) D
39 . I GMRSITE(1)["RADIAL"!(GMRSITE(1)["APICAL")!(GMRSITE(1)["BRACHIAL") D
40 . . S ^TMP($J,"GMRK","G"_(GJ*16+GCNTD+1))=GK-40/10
41 S ^TMP($J,"GMRK","G"_(GJ+1*16+GCNTD+1))=GK_$S(GMRVJ=1:"*",1:"")_$S(GI="T":GMRSITE,GI="P"&($L(GMRSITE," ")>3):" "_$P(GMRSITE," "),1:" ")
42 I GI="T",GK>0 S ^TMP($J,"GMRK","G"_(410+GCNTD))=$S(GMRVJ=1:"T*",1:"T")
43 I GK'="",GI="P","UNAVAILABLEPASSREFUSED"'[$$UP^XLFSTR(GK) D
44 . I GMRSITE(1)["RADIAL"!(GMRSITE(1)["APICAL")!(GMRSITE(1)["BRACHIAL") S ^TMP($J,"GMRK","G"_(430+GCNTD))=$S(GMRVJ=1:"P*",1:"P")
45 . S ^TMP($J,"GMRK","G"_(1600+GCNTD))=$S($L(GMRSITE," ")>3:$P(GMRSITE," ",2,4),1:GMRSITE)
46 I GK>0,GI="T" S ^TMP($J,"GMRK","G"_(GJ*16+GCNTD+1))=$S(^("G"_(GJ*16+GCNTD+1))<0.3:0.3,^("G"_(GJ*16+GCNTD+1))>11.6:11.6,1:^("G"_(GJ*16+GCNTD+1))) S:^("G"_(GJ*16+GCNTD+1))<0.4!(^("G"_(GJ*16+GCNTD+1))>11.5) ^TMP($J,"GMRK","G"_(410+GCNTD))="T**"
47 I GK'="",GI="P","UNAVAILABLEPASSREFUSED"'[$$UP^XLFSTR(GK) D
48 . I GMRSITE(1)["RADIAL"!(GMRSITE(1)["APICAL")!(GMRSITE(1)["BRACHIAL") D
49 . . S ^TMP($J,"GMRK","G"_(GJ*16+GCNTD+1))=$S(^("G"_(GJ*16+GCNTD+1))<0.3:0.3,^("G"_(GJ*16+GCNTD+1))>11.6:11.6,1:^("G"_(GJ*16+GCNTD+1))) S:^("G"_(GJ*16+GCNTD+1))<0.4!(^("G"_(GJ*16+GCNTD+1))>11.5) ^TMP($J,"GMRK","G"_(430+GCNTD))="P**"
50 Q
51OUTP ;PRINT OUTPUT
52 S J=-8.7,J(1)=162 D WRTLN^GMVHG3
53PAIN ;PRINT PAIN
54 S J=-9.1,J(1)=1661 D
55 . S I(1)="" F I=1:1:5 S I(2)=I-1,I(1)=I(1)_"PA"_(1.6*I(2)+0.2)_","_J_";LB"_^TMP($J,"GMRK","G"_(J(1)+I(2)))_"#;"
56 . W !,I(1) S I(1)="" F I=6:1:10 S I(2)=I-1,I(1)=I(1)_"PA"_(1.6*I(2)+0.2)_","_J_";LB"_^TMP($J,"GMRK","G"_(J(1)+I(2)))_"#;"
57 . W !,I(1) Q
58PTID ;PRINT PATIENT ID
59 W !,"SD1,277,2,1,4,9,5,1,6,5,7,4;SS;PA-1,-11.3;LB"_^TMP($J,"GMRK","G194")_"#;PA-1,-11.6;LB"_^("G196")_" "_^("G197")_"#;"
60 W !,"PA-1,-11.9;LB"_^TMP($J,"GMRK","G198")_"#;PA7,-11.9;LB"_^("G200")_"#;PA-1,-12.2;LB"_GMRDIV_"#;PA7,-12.2;LB"_^("G199")_"#;"
61 W !,"PA-1,-12.5;LB"_GSTRFIN_"#;" Q
Note: See TracBrowser for help on using the repository browser.