Python has some interesting functionalities and libraries then can be leveraged inside PowerBI. This video explains how to do that using simple examples and dataset.
1. Code for bar chart:
import pandas
import matplotlib.pyplot as plt
plt.bar(dataset.Region,dataset.Sales)
plt.show()
2. Code for pairplot:
import pandas as pd
import seaborn as sns
import matplotlib.pyplot as plt
Set theme for the plot
sns.set_theme(style="whitegrid")
sns.set()
Use pairplot with colors based on "Region"
sns.pairplot(
dataset[["Region", "Profit", "Quantity"]],
hue="Region", # Color by 'Region'
palette="Set1" # Choose a color palette (e.g., Set2, Set1, etc.)
)
plt.show()
On this page of the site you can watch the video online How to use Python inside PowerBI with a duration of hours minute second in good quality, which was uploaded by the user Datascience with Manu 26 October 2024, share the link with friends and acquaintances, this video has already been watched 407 times on youtube and it was liked by 6 viewers. Enjoy your viewing!