Jump to content
We've recently updated our Privacy Statement, available here. ×

Could not execute function call error in Tibco Spotfire. Please help me find the solution


Pooja Shetty

Recommended Posts

In Spotfire application , I place the path of the "R Engine" folderunder Settings tab>File Path,(R Engine folder is placed in my desktop)It should load the R data at the backend and display the data within the applicationbut it is throwing the below error.

TIBCO Enterprise Runtime for R returned an error: 'Error: Cannot open layer

eval(expr, envir, enclos)

eval(expr, envir, enclos)

readOGR(dsn = Shapefile_Input_Path, layer = NeighborhoodName)

suppressMessages(ogr_info

Link to comment
Share on other sites

Hi There - very difficult to troubleshoot from afar, but you appear to have a problem with the layer variable in your code. What is it referencing Does the variable contain the name of the layer you intend to open Does the layer exist in the ShapeFile I'm very wary of naming variables and calling functions like this:

layer = layer - it's bad practice in my opinion. How do you know what consitutes the name of the parameter and what is the variable Far better to use layer = myLayer or even to hardcode it for testing purposes - layer="My City"

I don't understand what you mean by:

Settings tab>File Path,(R Engine folder is placed in my desktop)

 

That's very bizarre. Spotfire has its own TERR engine, referenced by default within Spotfire - you're already using it.

You can always troubleshoot R code from RStudio - there is lots of documentation out there for using TERR with RStudio.

Andrew (TIBCO Data Science)

Link to comment
Share on other sites

Thanks for the reply..Settings tab>File Path,(R Engine folder is placed in my desktop)-This is in Spotfire application where I add "R Enginge "folderI also find the below error."rgdal package" is already available in the library Error :Could not execute function call.

TIBCO Spotfire Statistics Services returned an error: 'Error: restricted call to find.package for package rgdal

eval(expr, envir, enclos)

eval(expr, envir, enclos)

suppressWarnings(suppressMessages(library(rgdal, lib.loc = RFilePath)))

withCallingHandlers(expr, warning = .suppressWarningsHandlerFn)

suppressMessages(library(rgdal, lib.loc = RFilePath))

withCallingHandlers(expr, message = function(e)

library(rgdal, lib.loc = RFilePath)

find.package(package, lib.loc, verbose = verbose, quiet = TRUE)'.

at Spotfire.Dxp.Data.DataFunctions.Executors.RemoteFunctionClient.OnExecuting()

at Spotfire.Dxp.Data.DataFunctions.Executors.AbstractFunctionClient.<RunFunction>d__0.MoveNext()

at Spotfire.Dxp.Data.DataFunctions.Executors.SPlusFunctionExecutor.<ExecuteFunction>d__0.MoveNext()

at Spotfire.Dxp.Data.DataFunctions.DataFunctionExecutorService.<ExecuteFunction>d__6.MoveNext()

Could not execute function call.

TIBCO Spotfire Statistics Services returned an error: 'Error: restricted call to find.package for package rgdal

eval(expr, envir, enclos)

eval(expr, envir, enclos)

suppressWarnings(suppressMessages(library(rgdal, lib.loc = RFilePath)))

withCallingHandlers(expr, warning = .suppressWarningsHandlerFn)

suppressMessages(library(rgdal, lib.loc = RFilePath))

withCallingHandlers(expr, message = function(e)

library(rgdal, lib.loc = RFilePath)

find.package(package, lib.loc, verbose = verbose, quiet = TRUE)'.

at Spotfire.Dxp.Data.DataFunctions.Executors.RemoteFunctionClient.OnExecuting()

at Spotfire.Dxp.Data.DataFunctions.Executors.AbstractFunctionClient.<RunFunction>d__0.MoveNext()

at Spotfire.Dxp.Data.DataFunctions.Executors.SPlusFunctionExecutor.<ExecuteFunction>d__0.MoveNext()

at Spotfire.Dxp.Data.DataFunctions.DataFunctionExecutorService.<ExecuteFunction>d__6.MoveNext()

Could not execute function call.

TIBCO Spotfire Statistics Services returned an error: 'Error: restricted call to find.package for package rgdal

eval(expr, envir, enclos)

eval(expr, envir, enclos)

suppressWarnings(suppressMessages(library(rgdal, lib.loc = RFilePath)))

withCallingHandlers(expr, warning = .suppressWarningsHandlerFn)

suppressMessages(library(rgdal, lib.loc = RFilePath))

withCallingHandlers(expr, message = function(e)

library(rgdal, lib.loc = RFilePath)

find.package(package, lib.loc, verbose = verbose, quiet = TRUE)'.

at Spotfire.Dxp.Data.DataFunctions.Executors.RemoteFunctionClient.OnExecuting()

at Spotfire.Dxp.Data.DataFunctions.Executors.AbstractFunctionClient.<RunFunction>d__0.MoveNext()

at Spotfire.Dxp.Data.DataFunctions.Executors.SPlusFunctionExecutor.<ExecuteFunction>d__0.MoveNext()

at Spotfire.Dxp.Data.DataFunctions.DataFunctionExecutorService.<ExecuteFunction>d__6.MoveNext()

Link to comment
Share on other sites

your earlier comment mentions TSSS, so you are not running local TERR but either TERR or R through the statistical server. It looks like you are trying to read from the TSSS file system, which is normally restricted. It does depend on the versions of both Spotfire and TSSS. 
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...