你的第一個 inner join
你要找出芝加哥計程車最常使用的燃料種類。為了完成分析,你需要將 taxi_owners 與 taxi_veh 兩個資料表,依照 vid 欄位合併。接著就能在合併後的資料表上搭配 .value_counts() 方法,找出最常見的 fuel_type。
因為整門課都會使用 pandas,在每個練習中套件都已經以 pd 預先載入。另外,taxi_owners 與 taxi_veh 這兩個 DataFrame 也都已為你載入。
本練習屬於課程
使用 pandas 進行資料表連接
動手互動練習
試著完成這個範例程式碼,體驗一下這個練習。
# Merge the taxi_owners and taxi_veh tables
taxi_own_veh = taxi_owners.____
# Print the column names of the taxi_own_veh
print(taxi_own_veh.columns)