I want to plot two dataframes in one 3D scatterplot.
This is the code I have for one dataframe:
import seaborn as sns
from mpl_toolkits.mplot3d import Axes3D
...
sns.set(style = "darkgrid")
fig = plt.figure()
ax = fig.add_subplot(111, projection = '3d')
x = df['xitem']
y = df['yitem']
z = df['zitem']
ax.set_xlabel("X Label")
ax.set_ylabel("Y Label")
ax.set_zlabel("Z Label")
ax.scatter(x, y, z)
plt.show()
I can't figure out how to adjust this so I have two different dataframes plotted on the same plot but with different colors. How can I do this?
Edit: I'm looking for how to use two dataframes for a 3D plot specifically.
