Advertisement
Bjarnidk

Untitled

Aug 22nd, 2020
3,435
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Ada 15.92 KB | None | 0 0
  1. clear
  2. use "C:\Users\GlaDOS\OneDrive\SDU\Neuro research\AndreasAneurysm\dataCleanup\useDO"
  3.  
  4. //Sorterer hvor mange aneurysmer pt har
  5. gen numberOfAn = .
  6. replace numberOfAn = 1 if !missing(placement_of_the_au_1)
  7. replace numberOfAn = 2 if !missing(placement_of_the_au_1, placement_of_the_au_2)
  8. replace numberOfAn = 3 if !missing(placement_of_the_au_1, placement_of_the_au_2, placement_of_the_au_3)
  9. replace numberOfAn = 4 if !missing(placement_of_the_au_1, placement_of_the_au_2, placement_of_the_au_3, placement_of_the_au_4)
  10. replace numberOfAn = 5 if !missing(placement_of_the_au_1, placement_of_the_au_2, placement_of_the_au_3, placement_of_the_au_4, placement_of_the_au_5)
  11.  
  12.  
  13. egen sizeAn1 = rowmax(sz_anu_in_ica sz_anu_in_mca sz_anu_in_aca sz_anu_in_acom sz_anu_in_pcom sz_anu_a_basilaris sz_anu_in_pica sz_anu_with_other_local)
  14.  
  15. egen sizeAn2 = rowmax(sz_anu_in_ica_2 sz_anu_in_mca_2 sz_anu_in_aca_2 sz_anu_in_acom_2 sz_anu_in_pcom_2 sz_anu_a_basilaris_2 sz_anu_in_pica_2 sz_anu_with_other_local_2)
  16.  
  17. egen sizeAn3 = rowmax(sz_anu_in_ica_3 sz_anu_in_mca_3 sz_anu_in_aca_3 sz_anu_in_acom_3 sz_anu_in_pcom_3 sz_anu_a_basilaris_3 sz_anu_in_pica_3 sz_anu_with_other_local_3)
  18.  
  19. egen sizeAn4 = rowmax(sz_anu_in_ica_4 sz_anu_in_mca_4 sz_anu_in_aca_4 sz_anu_in_acom_4 sz_anu_in_pcom_4 sz_anu_a_basilaris_4 sz_anu_in_pica_4 sz_anu_with_other_local_4)
  20.  
  21. egen sizeAn5 = rowmax(sz_anu_in_ica_5 sz_anu_in_mca_5 sz_anu_in_aca_5 sz_anu_in_acom_5 sz_anu_in_pcom_5 sz_anu_a_basilaris_5 sz_anu_in_pica_5 sz_anu_with_other_local_5)
  22.  
  23. gen aneurysmNumber = 1 if !missing(placement_of_the_au_1)
  24. replace aneurysmNumber = 2 if !missing(placement_of_the_au_2)
  25. replace aneurysmNumber = 3 if !missing(placement_of_the_au_3)
  26. replace aneurysmNumber = 4 if !missing(placement_of_the_au_4)
  27. replace aneurysmNumber = 5 if !missing(placement_of_the_au_5)
  28.  
  29. //Laver en obs for hver pt per aneurysme
  30. expand 2 if aneurysmNumber == 2
  31. expand 3 if aneurysmNumber == 3
  32. expand 4 if aneurysmNumber == 4
  33. expand 5 if aneurysmNumber == 5
  34.  
  35. //Laver en identifier til aneurysmer
  36. gen anIdentify = 1 if !missing(placement_of_the_au_1)
  37. replace anIdentify = 2 if !missing(placement_of_the_au_2)
  38. replace anIdentify = 3 if !missing(placement_of_the_au_3)
  39. replace anIdentify = 4 if !missing(placement_of_the_au_4)
  40. replace anIdentify = 5 if !missing(placement_of_the_au_5)
  41.  
  42. //Sorterer data aneurysmer til specifikt ID
  43. bysort record_id: gen aneurysm_id = _n
  44.  
  45. //Sorterer location efter aneurysmer
  46. gen location = .
  47. replace location = placement_of_the_au_1 if aneurysm_id == 1
  48. replace location = placement_of_the_au_2 if aneurysm_id == 2
  49. replace location = placement_of_the_au_3 if aneurysm_id == 3
  50. replace location = placement_of_the_au_4 if aneurysm_id == 4
  51. replace location = placement_of_the_au_5 if aneurysm_id == 5
  52.  
  53. //Sorterer size efter aneurysmer
  54. gen anSize = .
  55. replace anSize = sizeAn1 if aneurysm_id == 1
  56. replace anSize = sizeAn2 if aneurysm_id == 2
  57. replace anSize = sizeAn3 if aneurysm_id == 3
  58. replace anSize = sizeAn4 if aneurysm_id == 4
  59. replace anSize = sizeAn5 if aneurysm_id == 5
  60.  
  61. //Sorterer treatment efter aneurysmer
  62. gen treatmentChoice = .
  63. replace treatmentChoice = choice_of_treatment if aneurysm_id == 1
  64. replace treatmentChoice = choice_of_treatment_2 if aneurysm_id == 2
  65. replace treatmentChoice = choice_of_treatment_3 if aneurysm_id == 3
  66. replace treatmentChoice = choice_of_treatment_4 if aneurysm_id == 4
  67. replace treatmentChoice = choice_of_treatment_5 if aneurysm_id == 5
  68.  
  69. //Sorterer kirurgiske komp til aneurysmer
  70. gen compSurgery = .
  71. replace compSurgery = surgical_comps if aneurysm_id == 1
  72. replace compSurgery = surgical_comps_2 if aneurysm_id == 2
  73. replace compSurgery = surgical_comps_3 if aneurysm_id == 3
  74. replace compSurgery = surgical_comps_4 if aneurysm_id == 4
  75. replace compSurgery = surgical_comps_5 if aneurysm_id == 5
  76.  
  77. //Sorterer stent komp til aneurysmer
  78. gen compStent = .
  79. replace compStent = comp_stenting if aneurysm_id == 1
  80. replace compStent = comp_stenting_2 if aneurysm_id == 2
  81. replace compStent = comp_stenting_3 if aneurysm_id == 3
  82. replace compStent = comp_stenting_4 if aneurysm_id == 4
  83. replace compStent = comp_stenting_5 if aneurysm_id == 5
  84.  
  85. //Sorterer coil komp til aneurysmer
  86. gen compCoil = .
  87. replace compCoil = comp_coil if aneurysm_id == 1
  88. replace compCoil = comp_coil_2 if aneurysm_id == 2
  89. replace compCoil = comp_coil_3 if aneurysm_id == 3
  90. replace compCoil = comp_coil_4 if aneurysm_id == 4
  91. replace compCoil = comp_coil_5 if aneurysm_id == 5
  92.  
  93. //Sorterer coil eller stent komp til aneurysmer
  94. gen compCoilStent = .
  95. replace compCoilStent = comp_co_st if aneurysm_id == 1
  96. replace compCoilStent = comp_co_st_2 if aneurysm_id == 2
  97. replace compCoilStent = comp_co_st_3 if aneurysm_id == 3
  98. replace compCoilStent = comp_co_st_4 if aneurysm_id == 4
  99. replace compCoilStent = comp_co_st_5 if aneurysm_id == 5
  100.  
  101. //Sorterer en komplikation lige meget hvilken
  102. gen compAtAll = .
  103. replace compAtAll = 0 if compSurgery == 0 | compStent == 0 | compCoil == 0 | compCoilStent == 0
  104. replace compAtAll = 1 if compSurgery == 1 | compStent == 1 | compCoil == 1 | compCoilStent == 1
  105.  
  106. //Fjerner (4) values som ikke var hele integers
  107. replace treatmentChoice = . if !mod(treatmentChoice, 1) == 0
  108.  
  109. //////////////////STENT//////////////////////
  110.  
  111. //gen komp variabel
  112. gen stentAndet = .
  113.  
  114. //0 hvis post er 0
  115. foreach v of var comp_post_stent*___8 {
  116.     replace stentAndet = 0 if `v' == 0
  117. }
  118.  
  119. //override til 1 hvis post er 1
  120. foreach v of var comp_post_stent*___8 {
  121.     replace stentAndet = 1 if `v' == 1
  122. }
  123.  
  124. //2 pt for andet
  125.  
  126. gen stentInfekt = .
  127.  
  128. foreach v of var comp_post_stent*___1 {
  129.     replace stentInfekt = 0 if `v' == 0
  130. }
  131.  
  132. foreach v of var comp_post_stent*___1 {
  133.     replace stentInfekt = 1 if `v' == 1
  134. }
  135.  
  136. gen stentHematom = .
  137.  
  138. foreach v of var comp_post_stent*___2 {
  139.     replace stentHematom = 0 if `v' == 0
  140. }
  141.  
  142. foreach v of var comp_post_stent*___2 {
  143.     replace stentHematom = 1 if `v' == 1
  144. }
  145.  
  146. gen stentSepsis = .
  147.  
  148. foreach v of var comp_post_stent*___3 {
  149.     replace stentSepsis = 0 if `v' == 0
  150. }
  151.  
  152. foreach v of var comp_post_stent*___3 {
  153.     replace stentSepsis = 1 if `v' == 1
  154. }
  155.  
  156. gen stentDVT = .
  157.  
  158. foreach v of var comp_post_stent*___4 {
  159.     replace stentDVT = 0 if `v' == 0
  160. }
  161.  
  162. foreach v of var comp_post_stent*___4 {
  163.     replace stentDVT = 1 if `v' == 1
  164. }
  165.  
  166. gen stentMors = .
  167.  
  168. foreach v of var comp_post_stent*___5 {
  169.     replace stentMors = 0 if `v' == 0
  170. }
  171.  
  172. foreach v of var comp_post_stent*___5 {
  173.     replace stentMors = 1 if `v' == 1
  174. }
  175.  
  176. gen stentNeuroKomp = .
  177.  
  178. foreach v of var comp_post_stent*___6 {
  179.     replace stentNeuroKomp = 0 if `v' == 0
  180. }
  181.  
  182. foreach v of var comp_post_stent*___6 {
  183.     replace stentNeuroKomp = 1 if `v' == 1
  184. }
  185.  
  186. //5 pt for neuro
  187.  
  188. gen stentHydro = .
  189.  
  190. foreach v of var comp_post_stent*___7 {
  191.     replace stentHydro = 0 if `v' == 0
  192. }
  193.  
  194. foreach v of var comp_post_stent*___7 {
  195.     replace stentHydro = 1 if `v' == 1
  196. }
  197.  
  198. gen stentKramper = .
  199.  
  200. foreach v of var comp_post_stent*___10 {
  201.     replace stentKramper = 0 if `v' == 0
  202. }
  203.  
  204. foreach v of var comp_post_stent*___10 {
  205.     replace stentKramper = 1 if `v' == 1
  206. }
  207.  
  208. //alle andre patienter 0 komp..
  209.  
  210. /////////////////////STENT PERI/////////////////////////////////
  211.  
  212. gen stentPerStentTrombo = .
  213.  
  214. foreach v of var peropperative_comp_stent*___1 {
  215.     replace stentPerStentTrombo = 0 if `v' == 0
  216. }
  217.  
  218. foreach v of var peropperative_comp_stent*___1 {
  219.     replace stentPerStentTrombo = 1 if `v' == 1
  220. }
  221.  
  222. gen stentPerStentBrist = .
  223.  
  224. foreach v of var peropperative_comp_stent*___2 {
  225.     replace stentPerStentBrist = 0 if `v' == 0
  226. }
  227.  
  228. foreach v of var peropperative_comp_stent*___2 {
  229.     replace stentPerStentBrist = 1 if `v' == 1
  230. }
  231.  
  232. gen stentPerStentAndet = .
  233.  
  234. foreach v of var peropperative_comp_stent*___3 {
  235.     replace stentPerStentAndet = 0 if `v' == 0
  236. }
  237.  
  238. foreach v of var peropperative_comp_stent*___3 {
  239.     replace stentPerStentAndet = 1 if `v' == 1
  240. }
  241.  
  242.  
  243. ////////////////////////COIL POST/////////////////////////////
  244.  
  245. gen coilInfekt = .
  246.  
  247. foreach v of var comp_post_coil*___1 {
  248.     replace coilInfekt = 0 if `v' == 0
  249. }
  250.  
  251. foreach v of var comp_post_coil*___1 {
  252.     replace coilInfekt = 1 if `v' == 1
  253. }
  254.  
  255. gen coilHematom = .
  256.  
  257. foreach v of var comp_post_coil*___2 {
  258.     replace coilHematom = 0 if `v' == 0
  259. }
  260.  
  261. foreach v of var comp_post_coil*___2 {
  262.     replace coilHematom = 1 if `v' == 1
  263. }
  264.  
  265. //1 pt i heme
  266.  
  267. gen coilSepsis = .
  268.  
  269. foreach v of var comp_post_coil*___3 {
  270.     replace coilSepsis = 0 if `v' == 0
  271. }
  272.  
  273. foreach v of var comp_post_coil*___3 {
  274.     replace coilSepsis = 1 if `v' == 1
  275. }
  276.  
  277. gen coilDVT = .
  278.  
  279. foreach v of var comp_post_coil*___4 {
  280.     replace coilDVT = 0 if `v' == 0
  281. }
  282.  
  283. foreach v of var comp_post_coil*___4 {
  284.     replace coilDVT = 1 if `v' == 1
  285. }
  286.  
  287. gen coilMors = .
  288.  
  289. foreach v of var comp_post_coil*___5 {
  290.     replace coilMors = 0 if `v' == 0
  291. }
  292.  
  293. foreach v of var comp_post_coil*___5 {
  294.     replace coilMors = 1 if `v' == 1
  295. }
  296.  
  297. gen coilNeuroTromb = .
  298.  
  299. foreach v of var comp_post_coil*___6 {
  300.     replace coilNeuroTromb = 0 if `v' == 0
  301. }
  302.  
  303. foreach v of var comp_post_coil*___6 {
  304.     replace coilNeuroTromb = 1 if `v' == 1
  305. }
  306.  
  307. //1 pt
  308.  
  309. gen coilHydro = .
  310.  
  311. foreach v of var comp_post_coil*___7 {
  312.     replace coilHydro = 0 if `v' == 0
  313. }
  314.  
  315. foreach v of var comp_post_coil*___7 {
  316.     replace coilHydro = 1 if `v' == 1
  317. }
  318.  
  319. gen coilAndet = .
  320.  
  321. foreach v of var comp_post_coil*___8 {
  322.     replace coilAndet = 0 if `v' == 0
  323. }
  324.  
  325. foreach v of var comp_post_coil*___8 {
  326.     replace coilAndet = 1 if `v' == 1
  327. }
  328.  
  329. //1 pt
  330.  
  331. gen coilKramper = .
  332.  
  333. foreach v of var comp_post_coil*___10 {
  334.     replace coilKramper = 0 if `v' == 0
  335. }
  336.  
  337. foreach v of var comp_post_coil*___10 {
  338.     replace coilKramper = 1 if `v' == 1
  339. }
  340.  
  341. //1 pt
  342.  
  343. ////////////////////////////COIL PERI////////////////////////////
  344.  
  345. gen coilPeriTrombo = .
  346.  
  347. foreach v of var peropperative_comp_coil*___1 {
  348.     replace coilPeriTrombo = 0 if `v' == 0
  349. }
  350.  
  351. foreach v of var peropperative_comp_coil*___1 {
  352.     replace coilPeriTrombo = 1 if `v' == 1
  353. }
  354. //2 pt
  355. gen coilPeriBrist = .
  356.  
  357. foreach v of var peropperative_comp_coil*___2 {
  358.     replace coilPeriBrist = 0 if `v' == 0
  359. }
  360.  
  361. foreach v of var peropperative_comp_coil*___2 {
  362.     replace coilPeriBrist = 1 if `v' == 1
  363. }
  364. //7 pt
  365.  
  366. gen coilPeriAndet = .
  367.  
  368. foreach v of var peropperative_comp_coil*___3 {
  369.     replace coilPeriAndet = 0 if `v' == 0
  370. }
  371.  
  372. foreach v of var peropperative_comp_coil*___3 {
  373.     replace coilPeriAndet = 1 if `v' == 1
  374. }
  375. //3 pt
  376.  
  377.  
  378.  
  379. ////////////////////////COMP POST SURG//////////////////////////
  380.  
  381. gen surgInfekt = .
  382.  
  383. foreach v of var comp_post_surgery*___1 {
  384.     replace surgInfekt = 0 if `v' == 0
  385. }
  386.  
  387. foreach v of var comp_post_surgery*___1 {
  388.     replace surgInfekt = 1 if `v' == 1
  389. }
  390. //4 pt
  391.  
  392. gen surgSepsis = .
  393.  
  394. foreach v of var comp_post_surgery*___3 {
  395.     replace surgSepsis = 0 if `v' == 0
  396. }
  397.  
  398. foreach v of var comp_post_surgery*___3 {
  399.     replace surgSepsis = 1 if `v' == 1
  400. }
  401. //1 pt
  402.  
  403. gen surgDVT = .
  404.  
  405. foreach v of var comp_post_surgery*___4 {
  406.     replace surgDVT = 0 if `v' == 0
  407. }
  408.  
  409. foreach v of var comp_post_surgery*___4 {
  410.     replace surgDVT = 1 if `v' == 1
  411. }
  412.  
  413. gen surgMors = .
  414.  
  415. foreach v of var comp_post_surgery*___5 {
  416.     replace surgMors = 0 if `v' == 0
  417. }
  418.  
  419. foreach v of var comp_post_surgery*___5 {
  420.     replace surgMors = 1 if `v' == 1
  421. }
  422.  
  423. gen surgNeuroTrombo = .
  424.  
  425. foreach v of var comp_post_surgery*___6 {
  426.     replace surgNeuroTrombo = 0 if `v' == 0
  427. }
  428.  
  429. foreach v of var comp_post_surgery*___6 {
  430.     replace surgNeuroTrombo = 1 if `v' == 1
  431. }
  432. //23 pt
  433.  
  434. gen surgHydro = .
  435.  
  436. foreach v of var comp_post_surgery*___7 {
  437.     replace surgHydro = 0 if `v' == 0
  438. }
  439.  
  440. foreach v of var comp_post_surgery*___7 {
  441.     replace surgHydro = 1 if `v' == 1
  442. }
  443.  
  444. gen surgAndet = .
  445.  
  446. foreach v of var comp_post_surgery*___8 {
  447.     replace surgAndet = 0 if `v' == 0
  448. }
  449.  
  450. foreach v of var comp_post_surgery*___8 {
  451.     replace surgAndet = 1 if `v' == 1
  452. }
  453. //15 pt
  454.  
  455. gen surgPostOpHema = .
  456.  
  457. foreach v of var comp_post_surgery*___9 {
  458.     replace surgPostOpHema = 0 if `v' == 0
  459. }
  460.  
  461. foreach v of var comp_post_surgery*___9 {
  462.     replace surgPostOpHema = 1 if `v' == 1
  463. }
  464. //4 pt
  465.  
  466. gen surgKramper = .
  467.  
  468. foreach v of var comp_post_surgery*___10 {
  469.     replace surgKramper = 0 if `v' == 0
  470. }
  471.  
  472. foreach v of var comp_post_surgery*___10 {
  473.     replace surgKramper = 1 if `v' == 1
  474. }
  475. //1 pt
  476.  
  477. ////////////////////////COMP PERI SURG/////////////////////////
  478.  
  479. //Bristning
  480. gen surgPeriBrist = .
  481.  
  482. foreach v of var peropper_compli*___1 {
  483.     replace surgPeriBrist = 0 if `v' == 0
  484. }
  485.  
  486. foreach v of var peropper_compli*___1 {
  487.     replace surgPeriBrist = 1 if `v' == 1
  488. }
  489. //2 pt
  490.  
  491. gen surgPeriAndet = .
  492.  
  493. foreach v of var peropper_compli*___2 {
  494.     replace surgPeriAndet = 0 if `v' == 0
  495. }
  496.  
  497. foreach v of var peropper_compli*___2 {
  498.     replace surgPeriAndet = 1 if `v' == 1
  499. }
  500. //6 pt
  501.  
  502. /////////////////////////////POST COMP STENT+COIL////////////////////////////////
  503.  
  504. gen scInfekt = .
  505.  
  506. foreach v of var complic_post_co_st*___1 {
  507.     replace scInfekt = 0 if `v' == 0
  508. }
  509.  
  510. foreach v of var complic_post_co_st*___1 {
  511.     replace scInfekt = 1 if `v' == 1
  512. }
  513. //1 pt
  514.  
  515. gen scHema = .
  516.  
  517. foreach v of var complic_post_co_st*___2 {
  518.     replace scHema = 0 if `v' == 0
  519. }
  520.  
  521. foreach v of var complic_post_co_st*___2 {
  522.     replace scHema = 1 if `v' == 1
  523. }
  524. //3 pt
  525.  
  526. gen scSepsis = .
  527.  
  528. foreach v of var complic_post_co_st*___3 {
  529.     replace scSepsis = 0 if `v' == 0
  530. }
  531.  
  532. foreach v of var complic_post_co_st*___3 {
  533.     replace scSepsis = 1 if `v' == 1
  534. }
  535.  
  536. gen scDVT = .
  537.  
  538. foreach v of var complic_post_co_st*___4 {
  539.     replace scDVT = 0 if `v' == 0
  540. }
  541.  
  542. foreach v of var complic_post_co_st*___4 {
  543.     replace scDVT = 1 if `v' == 1
  544. }
  545.  
  546. gen scMors = .
  547.  
  548. foreach v of var complic_post_co_st*___5 {
  549.     replace scMors = 0 if `v' == 0
  550. }
  551.  
  552. foreach v of var complic_post_co_st*___5 {
  553.     replace scMors = 1 if `v' == 1
  554. }
  555.  
  556. gen scNeurotromb = .
  557.  
  558. foreach v of var complic_post_co_st*___6 {
  559.     replace scNeurotromb = 0 if `v' == 0
  560. }
  561.  
  562. foreach v of var complic_post_co_st*___6 {
  563.     replace scNeurotromb = 1 if `v' == 1
  564. }
  565. //18 pt
  566.  
  567. gen scHydro = .
  568.  
  569. foreach v of var complic_post_co_st*___7 {
  570.     replace scHydro = 0 if `v' == 0
  571. }
  572.  
  573. foreach v of var complic_post_co_st*___7 {
  574.     replace scHydro = 1 if `v' == 1
  575. }
  576.  
  577. gen scAndet = .
  578.  
  579. foreach v of var complic_post_co_st*___8 {
  580.     replace scAndet = 0 if `v' == 0
  581. }
  582.  
  583. foreach v of var complic_post_co_st*___8 {
  584.     replace scAndet = 1 if `v' == 1
  585. }
  586. //7 pt
  587.  
  588. gen scKramper = .
  589.  
  590. foreach v of var complic_post_co_st*___10 {
  591.     replace scKramper = 0 if `v' == 0
  592. }
  593.  
  594. foreach v of var complic_post_co_st*___10 {
  595.     replace scKramper = 1 if `v' == 1
  596. }
  597.  
  598.  
  599. /////////////////////PERI SC//////////////////////////
  600.  
  601. gen scPeriTromboembo = .
  602.  
  603. foreach v of var perop_comp_co_st_coil*___1 {
  604.     replace scPeriTromboembo = 0 if `v' == 0
  605. }
  606.  
  607. foreach v of var perop_comp_co_st_coil*___1 {
  608.     replace scPeriTromboembo = 1 if `v' == 1
  609. }
  610. //2 pt
  611.  
  612. gen scPeriBrist = .
  613.  
  614. foreach v of var perop_comp_co_st_coil*___2 {
  615.     replace scPeriBrist = 0 if `v' == 0
  616. }
  617.  
  618. foreach v of var perop_comp_co_st_coil*___2 {
  619.     replace scPeriBrist = 1 if `v' == 1
  620. }
  621. //3 pt
  622.  
  623. gen scPeriAndet = .
  624.  
  625. foreach v of var perop_comp_co_st_coil*___3 {
  626.     replace scPeriAndet = 0 if `v' == 0
  627. }
  628.  
  629. foreach v of var perop_comp_co_st_coil*___3 {
  630.     replace scPeriAndet = 1 if `v' == 1
  631. }
  632.  
  633. /////////////////infektion////////////////////
  634.  
  635. gen infektion = 0 if !missing(stentInfekt, coilInfekt, surgInfekt, scInfekt)
  636. replace infektion = 1 if stentInfekt == 1 | coilInfekt == 1 | surgInfekt == 1 | scInfekt == 1
  637.  
  638. ///////////////sepsis////////////////////
  639.  
  640. gen sepsis = 0 if !missing(stentSepsis, coilSepsis, surgSepsis, scSepsis)
  641. replace sepsis = 1 if stentSepsis == 1 | coilSepsis == 1 | surgSepsis == 1 | scSepsis == 1
  642.  
  643. /////////////////DVT///////////////////
  644.  
  645. gen DVT = 0 if !missing(stentDVT, coilDVT, surgDVT, scDVT)
  646. replace DVT = 1 if stentDVT == 1 | coilDVT == 1 | surgDVT == 1 | scDVT == 1
  647.  
  648. ////////////////neurotromb//////////////////
  649. gen neurotromb = 0 if !missing(stentNeuroKomp, coilNeuroTromb, surgNeuroTrombo, scNeurotromb)
  650. replace neurotromb = 1 if stentNeuroKomp == 1 | coilNeuroTromb == 1 | surgNeuroTrombo == 1 | scNeurotromb == 1
  651.  
  652.  
  653. ///melogit compAtAll treatmentChoice || anIdentify:
  654.  
  655.  
  656.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement