Hi Carlos,
sorry for being to "very precise".
Of course the easiest way is to switch manually to Spyder and run the script. But what I am aiming for is an automated workflow. So I will try to explain this in more detail.
Our Microscope Control Software (ZEN Blue) is written in C# and used IronPython as the internal scripting language. That is the place where the user can automate their experiments. And this is where I wnat to start a "normal" python script within Spyder. Usually I start python scripts like this from inside the ZEN Blue software:
-------------------------IRON PYTHON SCRIPT IN ZEN BLUE (just parts) ------------------------
import clr
from System.Diagnostics import Process
...
# this is the location of the script use to plot the data
# use this version for a general approach -->; pass filename, X-column and Y-column to plot directly from the macro
script1 = r'C:\My Scripts\PlotData_Example.py' # this is a "normal" python script
# those are the parameters - filename, (X-Column and Y-Column)
# this one for the general approach
params1 = ' -f ' + csvfile + ' -x 2 -y 0 -r 2'
# start the data display script as an external application
app1 = Process();
app1.StartInfo.FileName = script1
app1.StartInfo.Arguments = params1
app1.Start()
----------------------------------------------------------------------------------
Since python script *.py are associated with python.exe the script will be started easily this way. But when I do this the data (numpy array, ...) are lost unless the script explicitly saves the data somewhere. but what I would like to do is starting the same script from our Software within Spyder. This way I would not have to save the data and reload again, because they would be available within Spyder for further processing.
For me (as a non-expert) the question is how to start my python Script within the active Sypder python or Ipython console. But I do not know yet, how to do it or even if this is possible at all.
I hope this explains the workflow a bit better.
Cheers, Sebi