Skip to main content


Scripts are used to inject custom Python code at certain positions in the Segna job running process. Any operation is possible as long as it begins and ends in a pandas dataframe.

Creating Scripts

Scripts can be created, viewed, and edited on the Scripts page of the Segna platform. Scripts are written in Python and provide an environment pre-loaded with pandas and NumPy. The input_dataframe variable contains the input data as a pandas DataFrame. Note that after performing your custom script logic, you must assign the output of the script to the output_dataframe variable.


When writing scripts, the pandas and numpy packages are pre-installed. Other packages are restricted, but if there is something else that you need please feel free to let us know!