Hello

Can someone help me create a dataset from my current dataset?

I have the following dataset:

Hospital | Therapy | var3 | var4 | var5 | Estimate_Therapy1 | Estimate_Therapy2 | Estimate_Therapy3 | Estimate_Therapy4
1 | 1 | 3 | 3 | 7 | 0.1 | . | . | .
1 | 2 | 3 | 3 | 7 | . | 0.3 | . | .
1 | 4 | 3 | 3 | 7 | . | . | . | 0.2
2 | 1 | 3 | 3 | 7 | 0.6 | . | . | .
2 | 2 | 3 | 3 | 7 | . | -0.2 | . | .
3 | 1 | 3 | 3 | 7 | 0.1 | . | . | .
3 | 2 | 3 | 3 | 7 | . | 0.3 | . | .
3 | 3 | 3 | 3 | 7 | . | . | -0.2 | .
3 | 4 | 3 | 3 | 7 | . | . | . | 0.2


And I would like to create the following 2 versions and export to excel:

# with all therapies (missing data)
Hospital | Estimate_Therapy1 | Estimate_Therapy2 | Estimate_Therapy3 | Estimate_Therapy4
1 | 0.1 | 0.3 | . | 0.2
2 | 0.6 | -0.2 | . | .
3 | 0.1 | 0.3 | -0.2 | 0.2

# with only those therapies used in all hospitals (no missing data)
Hospital | Estimate_Therapy1 | Estimate_Therapy2
1 | 0.1 | 0.3
2 | 0.6 | -0.2
3 | 0.1 | 0.3


Many thanks in advance!