Wrapping exec object in pyroot

Please read tips for efficient and successful posting and posting code

_ROOT Version: 6.18
_Platform: Mac Mojava
_Compiler: Clang


I’m trying to wrap the example from a previous discussion

in pyroot but without success. These two lines are the issue,

    TExec *ex = new TExec("ex","DrawCol();");


Any advice, thanks,


@etejedor can you take a look please?

Hi Damir,

Can you elaborate a bit more on what you would like to do, exactly?

You have some code in C++ that you want to execute from Python?

Yes; the same macro in the link provided but only in pyroot; The code will plot Graph points with different colors; I cannot map out this to pyroot. This passing of function TExec(“ex”,“DrawCol();”); doesn’t work,


So you translated the C++ macro in the other post to a Python script, and you are trying to run that script?

Or what is it exactly that you are running in Python? Can you attach/copy it here?

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.