tabihussain
New Member
- Joined
- Oct 24, 2017
- Messages
- 6
Hi there,
I really hope someone has a solution for this problem. I want to analyze data from a clinical lab in SPSS. The data I have has several thousand samples, so I want an easy way of transferring it in SPSS for analysis. Here is a screenshot of the data. Now the problem is against one patient, efficacy to a panel of drugs is tested and between patients, the panel of drugs that is tested can also vary. The data is pasted below. The left most column is the sample ID number as you can see the same ID number prevails for about 13 cases, so this is one patient's result. My problem is I want to export this data in spss in a way that all the drugs (Amikacin, Ampicillin etc etc) become variables (columns), each with values 1,0 etc for one patient, so that all data for one ID number/patient is limited to one row only. Is there any way to reorganize this data? If not a shortcut, at least less tedious than manually copying all rows for one ID? I would want the conversion to somewhat like the second table.
I would really appreciate any ideas.
Best Regards
Tabi
[TABLE="width: 783"]
<tbody>[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Amikacin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Amoxicillin + Clavulanic acid[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Ampicillin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Ceftriaxone[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Ciprofloxacin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Cotrimoxazole[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Fosfomycin[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Gentamicin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Imipenem[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Meropenem[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Nitrofurantoin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Piperacillin+Tazobactam[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Sulzone[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Doxycycline[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Gentamicin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Meropenem[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Amikacin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Polymyxin B[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Cotrimoxazole[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Tigecycline[/TD]
[TD]I[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Amoxicillin + Clavulanic acid[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Ceftriaxone[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Imipenem[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Ampicillin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Ciprofloxacin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Sulzone[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Piperacillin+Tazobactam[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Cotrimoxazole[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Ceftriaxone[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Piperacillin+Tazobactam[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Amikacin[/TD]
[TD]I[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Amoxicillin + Clavulanic acid[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Ciprofloxacin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Tigecycline[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Sulzone[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Doxycycline[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Gentamicin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Imipenem[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Meropenem[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Ampicillin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Tigecycline[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Doxycycline[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Ciprofloxacin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Gentamicin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Amikacin[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Piperacillin+Tazobactam[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Meropenem[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Amoxicillin + Clavulanic acid[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Ceftriaxone[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Sulzone[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Imipenem[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Cotrimoxazole[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
Intended Output
[TABLE="width: 1408"]
<colgroup><col width="64" span="22" style="width:48pt"> </colgroup><tbody>[TR]
[TD="width: 64"]ID number[/TD]
[TD="width: 64"]Age[/TD]
[TD="width: 64"]Gender[/TD]
[TD="width: 64"]Isolate[/TD]
[TD="width: 64"]Amikacin[/TD]
[TD="width: 64"]Amoxicillin + Clavulanic acid[/TD]
[TD="width: 64"]Ampicillin[/TD]
[TD="width: 64"]Ceftriaxone[/TD]
[TD="width: 64"]Cefipime[/TD]
[TD="width: 64"]Ceftazidine[/TD]
[TD="width: 64"]Sulzone[/TD]
[TD="width: 64"]Tigecycline[/TD]
[TD="width: 64"]Ciprofloxacin[/TD]
[TD="width: 64"]Cotrimoxazole[/TD]
[TD="width: 64"]Doxycycline[/TD]
[TD="width: 64"]Fosfomycin[/TD]
[TD="width: 64"]Gentamicin[/TD]
[TD="width: 64"]Imipenem[/TD]
[TD="width: 64"]Meropenem[/TD]
[TD="width: 64"]Nitrofurantoin[/TD]
[TD="width: 64"]Piperacillin+Tazobactam[/TD]
[TD="width: 64"]Polymyxin B[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]80[/TD]
[TD]M[/TD]
[TD]Klebsiella [/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]S[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[/TR]
</tbody>[/TABLE]
I really hope someone has a solution for this problem. I want to analyze data from a clinical lab in SPSS. The data I have has several thousand samples, so I want an easy way of transferring it in SPSS for analysis. Here is a screenshot of the data. Now the problem is against one patient, efficacy to a panel of drugs is tested and between patients, the panel of drugs that is tested can also vary. The data is pasted below. The left most column is the sample ID number as you can see the same ID number prevails for about 13 cases, so this is one patient's result. My problem is I want to export this data in spss in a way that all the drugs (Amikacin, Ampicillin etc etc) become variables (columns), each with values 1,0 etc for one patient, so that all data for one ID number/patient is limited to one row only. Is there any way to reorganize this data? If not a shortcut, at least less tedious than manually copying all rows for one ID? I would want the conversion to somewhat like the second table.
I would really appreciate any ideas.
Best Regards
Tabi
[TABLE="width: 783"]
<tbody>[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Amikacin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Amoxicillin + Clavulanic acid[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Ampicillin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Ceftriaxone[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Ciprofloxacin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Cotrimoxazole[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Fosfomycin[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Gentamicin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Imipenem[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Meropenem[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Nitrofurantoin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Piperacillin+Tazobactam[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]05:50.7[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]80[/TD]
[TD]Y[/TD]
[TD]Urine For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Sulzone[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Doxycycline[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Gentamicin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Meropenem[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Amikacin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Polymyxin B[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Cotrimoxazole[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Tigecycline[/TD]
[TD]I[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Amoxicillin + Clavulanic acid[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Ceftriaxone[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Imipenem[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Ampicillin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Ciprofloxacin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Sulzone[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423279[/TD]
[TD="align: right"]40:50.3[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]55[/TD]
[TD]Y[/TD]
[TD]NBL for C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Piperacillin+Tazobactam[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Cotrimoxazole[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Ceftriaxone[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Piperacillin+Tazobactam[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Amikacin[/TD]
[TD]I[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Amoxicillin + Clavulanic acid[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Ciprofloxacin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Tigecycline[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Sulzone[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Doxycycline[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Gentamicin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Imipenem[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Meropenem[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423316[/TD]
[TD="align: right"]21:01.9[/TD]
[TD]***[/TD]
[TD]M[/TD]
[TD="align: right"]60[/TD]
[TD]Y[/TD]
[TD]Fluid For C/S[/TD]
[TD]Klebsiella pneumoniae[/TD]
[TD]Ampicillin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Tigecycline[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Doxycycline[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Ciprofloxacin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Gentamicin[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Amikacin[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Piperacillin+Tazobactam[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Meropenem[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Amoxicillin + Clavulanic acid[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Ceftriaxone[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Sulzone[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Imipenem[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"]14423680[/TD]
[TD="align: right"]36:02.2[/TD]
[TD]*[/TD]
[TD]M[/TD]
[TD="align: right"]12[/TD]
[TD]D[/TD]
[TD]Pus for C/S[/TD]
[TD]Klebsiella oxytoca[/TD]
[TD]Cotrimoxazole[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
Intended Output
[TABLE="width: 1408"]
<colgroup><col width="64" span="22" style="width:48pt"> </colgroup><tbody>[TR]
[TD="width: 64"]ID number[/TD]
[TD="width: 64"]Age[/TD]
[TD="width: 64"]Gender[/TD]
[TD="width: 64"]Isolate[/TD]
[TD="width: 64"]Amikacin[/TD]
[TD="width: 64"]Amoxicillin + Clavulanic acid[/TD]
[TD="width: 64"]Ampicillin[/TD]
[TD="width: 64"]Ceftriaxone[/TD]
[TD="width: 64"]Cefipime[/TD]
[TD="width: 64"]Ceftazidine[/TD]
[TD="width: 64"]Sulzone[/TD]
[TD="width: 64"]Tigecycline[/TD]
[TD="width: 64"]Ciprofloxacin[/TD]
[TD="width: 64"]Cotrimoxazole[/TD]
[TD="width: 64"]Doxycycline[/TD]
[TD="width: 64"]Fosfomycin[/TD]
[TD="width: 64"]Gentamicin[/TD]
[TD="width: 64"]Imipenem[/TD]
[TD="width: 64"]Meropenem[/TD]
[TD="width: 64"]Nitrofurantoin[/TD]
[TD="width: 64"]Piperacillin+Tazobactam[/TD]
[TD="width: 64"]Polymyxin B[/TD]
[/TR]
[TR]
[TD="align: right"]14423230[/TD]
[TD="align: right"]80[/TD]
[TD]M[/TD]
[TD]Klebsiella [/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]S[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[TD]R[/TD]
[/TR]
</tbody>[/TABLE]