Section 8 unit 19 primer (2)

hello,

 

# Right join
print (pd.merge(left_df, right_df, how='outer', on='Sector'))
      Company_x                Sector  id_x Company_y  id_y
0       Infosys                    IT     1       TCS     2
1           SBI                 Banks     2     ICICI     4
2  Asian Paints  Paints and Varnishes     3       NaN   NaN
3        Maruti                  Auto     4       M&M     5
4    Sun Pharma                Pharma     5     Lupin     3
5           NaN                 Power   NaN      NTPC     1

isn't 'outer' supposed to be 'right' ?

please clarify.

thank you.

Thanks for pointing that one as well. We will the fix the code to 'right'.



New code line should be :



print (pd.merge(left_df, right_df, how='right', on='Sector')) 



Thanks

np… thanks