I'm using the funtion pivot_longer instead of spread. My issue is that I want to pivot_longer 4 columns into 3 new columns (Key, Value1, Value2).
For example: I have CapBusiness, CapTourist, PaxBusiness, PaxTourist.
What I want to achieve is: Cabin, Cap, Pax.
Cabin must have just 2 values: Business and Tourist.
Cap and Pax must be the values of each one.
To help us help you, could you please prepare a reproducible example (reprex) illustrating your issue? Please have a look at this guide, to see how to create one: