Jump to content

Recommended Posts

Posted

I am trying to get python data functions working in my dashboard. I've followed the instructions as per this link:https://community.spotfire.com/wiki/python-data-function-tibco-spotfire

When I run a function, I can import modules without error, I can write some simple code and run without error, I can even have input parameters in my code without error. But as soon as I set anoutput parameter,i get the following error:

Could not execute function call 'Python Script DataFunction'

File not found: C:Usersluke.georgeAppDataLocalTemptmpBE84.stdf

I have seen the solution posted here:https://community.spotfire.com/questions/python-data-function-temp-file-not-found-python-engine-version-change, but this does not fix my problem.

Posted

It looks like you are using a custom extension of Python Data Function and not the native Python Data Function (available from 10.7 and onwards). Since I do not have the custom extension, I won't be able to test this with it.

With native PyDF, I was able to create a column which is twice of an existing column.

 

Create a simple script as shown above, and assign the input x to a type column and data type 'Integer'. If the column is of 'Real' data type, give it a Real data type. Don't give it multiple data types. I see that you have given multiple data types to your input parameter. After that, assign the output to a type column.

In Edit parameters, check the 'Refresh function automatically' checkbox.

In Input >> Input Handlers, select 'Columns' and select the column you want to multiply.In Output >>Output Handlers, select 'Columns' and click OK.

Posted
The reason I'm using the custom python extension and not a native python data function is because I want to see if I can use the python exytension to implement a work around to run python in the web player...but at this stage I can't even get it working in Analyst!
  • 2 weeks later...
Posted

I tried running the script with custom extension of Python Data Function and I was able to run it and achieve the desired output.

 

 

Ensure that your input and output values defined have the same data types.

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...