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

July 7 - July 17 | Round 2 of the Power BI Dataviz World Championships. Don't miss your chance! Learn more

Reply
Anonymous
Not applicable

Simple R script functions properly on Desktop, not in Service?

Just a simple panel of linear model diagnostic plots. Comes out as expected on Desktop, only comes out partially in the Service. Is this a known issue?

 

Script:

# Original Script. Please update your script content here and once completed copy below section back to the original editing window #
### The following code to create a dataframe and remove duplicated rows is always executed and acts as a preamble for your script: 

# dataset <- data.frame(TransactionDate, PayInAmt)
# dataset <- unique(dataset)

###

# includes
library(ggplot2)
library(scales)

# add index
dataset$pkid <- seq.int(nrow(dataset))

# build exponential decay model
dataset$LogPayIn <- log(dataset[,2])
exp_model <- lm(dataset$LogPayIn ~ dataset$pkid)

# generate predictions
#dataset$predictedValues <- exp(predict(exp_model, as.list(dataset$pkid)))

# plot residuals
par(mfrow = c(2, 2))
plot(exp_model)

Desktop output:

DesktopModelDiagnostics.jpg

 

Service output:

ServiceModelDiagnostics.jpg

4 REPLIES 4
Aron_Moore
Solution Specialist
Solution Specialist

Not all R packages are supported by the Power BI service.

 

Check this link https://docs.microsoft.com/en-us/power-bi/service-r-packages-support

Anonymous
Not applicable

The two in my script are on that page you linked.

I'm having the same issue, not sure when it started happening. Had a post up but someone marked it as spam...

 

According to the first two bullet points in the link Aron provided, I think some packages might be supported in Desktop but not Service if they're not published in CRAN. I'm pretty sure all mine are published on CRAN - is the package `grid` supported on Service?

If it's not, I'd be surprised since my error doesn't mention that and instead says no data, specifically no rows to aggregate.

 

What's the exact error you get in Service?

Anonymous
Not applicable

There was no error given visible to me. Just incorrect output. 😞



 

Helpful resources

Announcements
FabCon and SQLCon Barcelona 2026

FabCon & SQLCon – Barcelona 2026

Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.

60 days of Data Days Carousel

Data Days 2026

Join Fabric Data Days 2026: 60 days of free live/on-demand sessions, challenges, study groups, and certification opportunities.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.