I am trying to merge two DataFrames so they only merge based on matching values in a column 'diagnosis'. I am getting duplicates now from the first dataset and I only need to add columns that matches 0 or 1.
I have tried inner join, outer, left and right.
diagnosis radius_mean texture_mean perimeter_mean area_mean smoothness_mean compactness_mean concavity_mean concave points_mean symmetry_mean ... fractal_dimension_worst thickness size shape adhesion single nuclei chromatin nucleoli mitosis
0 1 17.99 10.38 122.80 1001.0 0.11840 0.27760 0.3001 0.1471 0.2419 ... 0.11890 8 10 10 8 7 10.0 9 7 1
1 1 17.99 10.38 122.80 1001.0 0.11840 0.27760 0.3001 0.1471 0.2419 ... 0.11890 5 3 3 3 2 3.0 4 4 1
2 1 17.99 10.38 122.80 1001.0 0.11840 0.27760 0.3001 0.1471 0.2419 ... 0.11890 8 7 5 10 7 9.0 5 5 4
3 1 17.99 10.38 122.80 1001.0 0.11840 0.27760 0.3001 0.1471 0.2419 ... 0.11890 7 4 6 4 6 1.0 4 3 1
4 1 17.99 10.38 122.80 1001.0 0.11840 0.27760 0.3001 0.1471 0.2419 ... 0.11890 10 7 7 6 4 10.0 4 1 2
5 1 17.99 10.38 122.80 1001.0 0.11840 0.27760 0.3001 0.1471 0.2419 ... 0.11890 7 3 2 10 5 10.0 5 4 4
6 1 17.99