我有一个看起来像这样的 R 数据框:
Country Property Value
Canada Capital Ottawa
Canada Population 38
Canada Language1 French
Canada Language2 English
United States Capital Washington
United States Population 280
United States Language1 English
United States Language2 NA
我想重新安排它,使它看起来像这样:
Country Capital Population Language1 Language2
Canada Ottawa 38 French English
United States Washington 280 English NA
有没有办法进行这种转变?谢谢。