Quantcast
Channel: Service topics
Viewing all articles
Browse latest Browse all 61813

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

$
0
0

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


Viewing all articles
Browse latest Browse all 61813

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>