Don't miss your chance to take exam DP-600 or DP-700 on us!
Request nowLearn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now
Hi everyone,
I'm in the process of finalizing my Forecasting Dashboard, but am having trouble actually explicitly showing my forecasting values in a non-plot. I surmised that the best way to go about this was to create the forecast in R and consume it in Power BI as shown here. However, upon running my script (shown below), I'm arriving at an error that I can't work around.
Details: "ADO.NET: R script error.
Loading required package: zoo
Attaching package: 'zoo'
The following objects are masked from 'package:base':
as.Date, as.Date.numeric
Loading required package: timeDate
Loading required package: methods
This is forecast 7.1
Error: 'FinalDataR.xlsx' does not exist in current working directory ('C:/Users/rohuyn/AppData/Local/Radio/RScriptWrapper_73e9db1f-04c3-457f-b569-fd897bce5981').
Execution halted
Does anyone have any ideas why this would be so, considering that whenever I input that same actual dataset to create my visualizations, PowerBI works fine? The idea is to have a forecasting dashboard that would be interactive in both visualization and actual values. Open to any suggestions/comments/guidance. Additionally, my forecasting script can be found below.
Best,
Ronnie
library(readxl)
library(forecast)
FinalData <- read_excel("FinalDataR.xlsx", sheet = "Final Raw Data")
ForecastData <- aggregate(Revenue~Month, data = FinalData, FUN = sum)
GeneralForecast <- ts(ForecastData$Revenue, start = 0, freq = 12)
fit <- arima((GeneralForecast), c(1, 1, 0),seasonal = list(order = c(1, 1, 0), period = 12))
ActualForecast <- forecast.Arima(fit, h = 5)
Solved! Go to Solution.
@rohuyn I think all you need to do is explicitly specify path of FinalDataR.xlsx instead of just the name as by default it will try to look into R directory but cannot find the file. So specify like C:/MyData/FinalDataR.xlsx and it should work.
@rohuyn I think all you need to do is explicitly specify path of FinalDataR.xlsx instead of just the name as by default it will try to look into R directory but cannot find the file. So specify like C:/MyData/FinalDataR.xlsx and it should work.
Perfect! Thanks, ankitpatira!
Just to clarify, this script now works due to ankitpatira's advice:
library(readxl)
library(forecast)
FinalData <- read_excel("C:\\Users\\rohuyn\\Desktop\\Team\\Team Projects\\Price Elasticity\\FinalDataR.xlsx", sheet = "Final Raw Data")
ForecastData <- aggregate(Revenue~Month, data = FinalData, FUN = sum)
GeneralForecast <- ts(ForecastData$Revenue, start = 0, freq = 12)
fit <- arima((GeneralForecast), c(1, 1, 0),seasonal = list(order = c(1, 1, 0), period = 12))
ActualForecast <- forecast.Arima(fit, h = 5)
I am trying to export data from power bi to csv file using R
I am giving the below command
write.csv(ALL_Data, "C:\\Users\\username\\Documents\\folder 1\\folder 2\\folder 3\\folder 4\\filename.csv")
I am getting the below error please help
DataSource.Error: ADO.NET: R script error.
Error in is.data.frame(x) : object 'ALL_Data' not found
Calls: write.csv ... eval.parent -> eval -> eval -> write.table -> is.data.frame
Execution halted
Details:
DataSourceKind=R
DataSourcePath=R
Message=R script error.
Error in is.data.frame(x) : object 'ALL_Data' not found
Calls: write.csv ... eval.parent -> eval -> eval -> write.table -> is.data.frame
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
Check out the February 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 10 | |
| 9 | |
| 7 | |
| 5 | |
| 5 |