Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Vote for your favorite vizzies from the Power BI Dataviz World Championship submissions. Vote now!

Reply
gianmariop
New Member

Usare Python nell'editor di Power Query

Nell'Usare Python nell'editor di Power Query ho inserito:

import pandas as pd

completedData = dataset.fillna(method='backfill', inplace=False)

dataset["completedValues"] =  completedData["SMI missing values"]

Ho installato correttamente pandas

Quando premo ok viene visualizzato il seguente errore:

DataSource.Error: ADO.NET: Þỳτћŏņ ѕсяїрť эřŗоŗ.

<pi>Traceback (most recent call last):

  File "C:\Users\Gianmario\PythonScriptWrapper_8c79fbbc-ec3a-4777-9692-8612321e0081\PythonScriptWrapper.PY", line 2, in <module>

    import os, pandas, matplotlib

ModuleNotFoundError: No module named 'matplotlib'

</pi>

Dettagli:

    DataSourceKind=Python

    DataSourcePath=Python

    Message=Þỳτћŏņ ѕсяїрť эřŗоŗ.

<pi>Traceback (most recent call last):

  File "C:\Users\Gianmario\PythonScriptWrapper_8c79fbbc-ec3a-4777-9692-8612321e0081\PythonScriptWrapper.PY", line 2, in <module>

    import os, pandas, matplotlib

ModuleNotFoundError: No module named 'matplotlib'

</pi>

    ErrorCode=-2147467259

    ExceptionType=Microsoft.PowerBI.Scripting.Python.Exceptions.PythonScriptRuntimeException

L'esempio lo scaricato dal seguente link: https://learn.microsoft.com/it-it/power-bi/connect-data/desktop-python-in-query-editor

1 ACCEPTED SOLUTION
lbendlin
Super User
Super User

ModuleNotFoundError: No module named 'matplotlib'

Your Python setup is incomplete.  You need to install pandas and matplotlib libraries.

View solution in original post

2 REPLIES 2
gianmariop
New Member

Grazie moltissime.

Ho installato IN PYTHON la libreria mancante

Nel mio caso: C:\Users\Gianmario\AppData\Local\Programs\Python\Python310\Scripts

Il percorso per raggiungere la sottodirectory dipende dalla cartella dove l'utente ha installato python sul PC. Sulla riga di comandi digito:

pip install matplotlib

Avevo intuito che l'errore era dovuto alla mancanza della libreria.

Grazie moltissime

 

lbendlin
Super User
Super User

ModuleNotFoundError: No module named 'matplotlib'

Your Python setup is incomplete.  You need to install pandas and matplotlib libraries.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

Vote for your favorite vizzies from the Power BI World Championship submissions!

Sticker Challenge 2026 Carousel

Join our Community Sticker Challenge 2026

If you love stickers, then you will definitely want to check out our Community Sticker Challenge!

January Power BI Update Carousel

Power BI Monthly Update - January 2026

Check out the January 2026 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.