Hi all, I would like to test adherence to Viral load testing protocol for pregnant women in our study:
If woman has an old HIV diagnosis she will have her VL test done immediately and if the levels are below 1000copies/ml the repeat test is done after 6 months
If above levels are 1000 and above then repeat test can be earlier at 3 months.
If guidelines adherent they should have at least 2 VL tests within 7 months of enrolment
If woman has a new HIV diagnosis, she starts her ART drugs immediately and her first VL test is done at 6 months post-enrolment. Timing of HIV diagnosis is defined by variable KP2.
KP2==0 should have at least 1 VL test within 7 months of enrolment.
Please give me a command to identify tests (VL_copies) done within 7 months of enrolment into our study (ENROLMENT DATE)
If a participant is old diagnosis (KP2==1) they should have at least 2 tests within that period which are at least 3 months apart
Second test only qualifies if the result previous one was 1000 copies (VL_copies) or more and should be at least 3 months or more
This will not apply if participant has no VL test ( defined by variable, Truemisses==1) or if they only have only one test during follow-up ( defined by variable, ntestVL==1)
See data sample below
----------------------- copy starting from the next line -----------------------
Code:
* Example generated by -dataex-. To install: ssc install dataex clear input str13 PatientID float(Collected VL_copies KP2) int(ntestVL ENROLLMENTDATE) float(Test_number1 Truemisses) "002729598-3" 21006 0 1 2 20507 1 0 "002729598-3" 21361 67 1 2 20507 2 0 "035374152-3" 20712 0 1 3 20523 1 0 "035374152-3" 21035 0 1 3 20523 2 0 "035374152-3" 21381 0 1 3 20523 3 0 "050657801-2" 20808 0 0 2 20628 1 0 "050657801-2" 21370 0 0 2 20628 2 0 "061047053-6" 20832 38 0 1 20599 1 0 "10020KT-0" 20572 1560 1 4 20600 1 0 "10020KT-0" 20685 0 1 4 20600 2 0 "10020KT-0" 21026 0 1 4 20600 3 0 "10020KT-0" 21559 0 1 4 20600 4 0 "10444-KT-2" 21066 0 1 1 20493 1 0 "10656KT-1" 20699 58 1 3 20535 1 0 "10656KT-1" 20979 58 1 3 20535 2 0 "10656KT-1" 21098 143 1 3 20535 3 0 "1065CH-0" . . 1 1 20471 . 1 "11258-29414" 20839 0 1 4 20605 1 0 "11258-29414" 21103 0 1 4 20605 2 0 "11258-29414" 21426 0 1 4 20605 3 0 end format %td Collected format %td ENROLLMENTDATE label values KP2 KP2_label label def KP2_label 0 "NewCase", modify label def KP2_label 1 "OldCase", modify
------------------ copy up to and including the previous line ------------------
Thank you!
If woman has an old HIV diagnosis she will have her VL test done immediately and if the levels are below 1000copies/ml the repeat test is done after 6 months
If above levels are 1000 and above then repeat test can be earlier at 3 months.
If guidelines adherent they should have at least 2 VL tests within 7 months of enrolment
If woman has a new HIV diagnosis, she starts her ART drugs immediately and her first VL test is done at 6 months post-enrolment. Timing of HIV diagnosis is defined by variable KP2.
KP2==0 should have at least 1 VL test within 7 months of enrolment.
Please give me a command to identify tests (VL_copies) done within 7 months of enrolment into our study (ENROLMENT DATE)
If a participant is old diagnosis (KP2==1) they should have at least 2 tests within that period which are at least 3 months apart
Second test only qualifies if the result previous one was 1000 copies (VL_copies) or more and should be at least 3 months or more
This will not apply if participant has no VL test ( defined by variable, Truemisses==1) or if they only have only one test during follow-up ( defined by variable, ntestVL==1)
See data sample below
----------------------- copy starting from the next line -----------------------
Code:
* Example generated by -dataex-. To install: ssc install dataex clear input str13 PatientID float(Collected VL_copies KP2) int(ntestVL ENROLLMENTDATE) float(Test_number1 Truemisses) "002729598-3" 21006 0 1 2 20507 1 0 "002729598-3" 21361 67 1 2 20507 2 0 "035374152-3" 20712 0 1 3 20523 1 0 "035374152-3" 21035 0 1 3 20523 2 0 "035374152-3" 21381 0 1 3 20523 3 0 "050657801-2" 20808 0 0 2 20628 1 0 "050657801-2" 21370 0 0 2 20628 2 0 "061047053-6" 20832 38 0 1 20599 1 0 "10020KT-0" 20572 1560 1 4 20600 1 0 "10020KT-0" 20685 0 1 4 20600 2 0 "10020KT-0" 21026 0 1 4 20600 3 0 "10020KT-0" 21559 0 1 4 20600 4 0 "10444-KT-2" 21066 0 1 1 20493 1 0 "10656KT-1" 20699 58 1 3 20535 1 0 "10656KT-1" 20979 58 1 3 20535 2 0 "10656KT-1" 21098 143 1 3 20535 3 0 "1065CH-0" . . 1 1 20471 . 1 "11258-29414" 20839 0 1 4 20605 1 0 "11258-29414" 21103 0 1 4 20605 2 0 "11258-29414" 21426 0 1 4 20605 3 0 end format %td Collected format %td ENROLLMENTDATE label values KP2 KP2_label label def KP2_label 0 "NewCase", modify label def KP2_label 1 "OldCase", modify
------------------ copy up to and including the previous line ------------------
Thank you!

Comment