/EDA

prices = all_data.groupby('Product').mean()['Price Each'] fig, ax1 = plt.subplots() ax2 = ax1.twinx() ax1.bar(products, quantity_ordered, color='g') ax2.plot(products, prices, 'b-') ax1.set_xlabel('Product Name') ax1.set_ylabel('Quantity Ordered', color='g') ax2.set_ylabel('Price($)', color='b') ax1.set_xticklabels(prodprices = all_data.groupby('Product').mean()['Price Each'] fig, ax1 = plt.subplots() ax2 = ax1.twinx() ax1.bar(products, quantity_ordered, color='g') ax2.plot(products, prices, 'b-') ax1.set_xlabel('Product Name') ax1.set_ylabel('Quantity Ordered', color='g') ax2.set_ylabel('Price($)', color='b') ax1.set_xticklabels(products, rotation='vertical', size=10) plt.show()ucts, rotation='vertical', size=10) plt.show()

Primary LanguageJupyter Notebook

This repository is not active