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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

SentimentR package generated an "ENVSXP" error

Hello Everyone,

 

I have been trying to perform text analysis using R and PowerBI, but one particular package - Sentimentr keeps giving me errors. 

 

I am using PowerBI desktop to run an R transformation using Sentimentr to create Sentiment scores for a text in the dataset.

Jigar_Shah_0-1629140703101.png

However, the moment I run the R-Code, I am presented with an error DataFormat.Error: ENVSXP without any specific information on what might have caused the error.

 

Jigar_Shah_1-1629140809919.png

 

Can you please help with understanding what might be wrong or how to circumvent the error for Sentiment results ?

 

Please note that while I am using PowerBI Desktop (August 2021 release), the code runs perfectly in R-Studio. Additionally, Sentimentr package is fully supported by PowerBI service to the latest version 2.7.1.

 

Thank you all for your time and help ! 

1 ACCEPTED SOLUTION

Hi  @Anonymous ,

 

Please follow this document to check whether you applied correct steps to run R script in the newest Power BI desktop.

 

Best Regards,
Kelly

Did I answer your question? Mark my reply as a solution!

View solution in original post

3 REPLIES 3
Greg_Deckler
Community Champion
Community Champion

@Anonymous This has come up before, check this thread: Re: Error in running an R script using sentimentr ... - Microsoft Power BI Community

 



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...
Anonymous
Not applicable

Thank you ! I did check the thread, but I think a resolution was not reached to the problem. The only other comment at that time (2019) was that the package was not supported by PowerBI, however, the package is now supported. Yet the problem still exists in the running the package through PowerBI. 

Hi  @Anonymous ,

 

Please follow this document to check whether you applied correct steps to run R script in the newest Power BI desktop.

 

Best Regards,
Kelly

Did I answer your question? Mark my reply as a solution!

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.