Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hi There!
Right now I can use plotly with Power BI via Python.
However, it shows the graph in another window:
Inside of Power BI I get this:
It says: It is not possible to show this visual. No Image was created. Check whether your Python script results in a standard device graph of Python.
Here is my code:
# dataset = pandas.DataFrame(Predito_Acumulado, Predito_Acumulado_l, Predito_Acumulado_u, DT_CONTATO)
# dataset = dataset.drop_duplicates()
# Cole ou digite aqui seu código de script:
baux = dataset
import plotly.graph_objs as go
fig = go.Figure([
go.Scatter(
name='Máximo',
x=baux['DT_CONTATO'],
y=baux['Predito_Acumulado'],
mode='lines',
line=dict(color='rgb(31, 119, 180)'),
),
go.Scatter(
name='Predição',
x=baux['DT_CONTATO'],
y=baux['Predito_Acumulado_u'],
mode='lines',
marker=dict(color="#444"),
line=dict(width=0),
showlegend=False
),
go.Scatter(
name='Mínimo',
x=baux['DT_CONTATO'],
y=baux['Predito_Acumulado_l'],
marker=dict(color="#444"),
line=dict(width=0),
mode='lines',
fillcolor='rgba(68, 68, 68, 0.3)',
fill='tonexty',
showlegend=False
)
])
fig.update_layout(
yaxis_title='Número de Matrículas',
hovermode="x"
)
fig.show()
Thanks!!
Solved! Go to Solution.
Hi, @guilhermesilva
Check this in the doc:
I'm not good at Python, I suggest you test whether a simple graph can be displayed normally, if not, you can rule out the code problem.
Make sure you have properly configured the python script:
Use an external Python IDE with Power BI - Power BI | Microsoft Docs
Did I answer your question? Please mark my reply as solution. Thank you very much.
If not, please feel free to ask me.
Best Regards,
Community Support Team _ Janey
Hi, @guilhermesilva
Check this in the doc:
I'm not good at Python, I suggest you test whether a simple graph can be displayed normally, if not, you can rule out the code problem.
Make sure you have properly configured the python script:
Use an external Python IDE with Power BI - Power BI | Microsoft Docs
Did I answer your question? Please mark my reply as solution. Thank you very much.
If not, please feel free to ask me.
Best Regards,
Community Support Team _ Janey
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
| User | Count |
|---|---|
| 57 | |
| 43 | |
| 41 | |
| 21 | |
| 17 |