RooRealVar map to a python function

Does anybody know how to map a RooRealVar to a python function?

[code]def myfunction(x):
return(x*x)

RooRealVar -> myfunction[/code]

I found RooFit.bindFunction which should do the job, but I can not make it work.

Thanks for any hint

Ivo

Hi,

haven’t tried this, but there’s a bindFunction that takes a TF1*, and you can construct a TF1 from a python function, so that may do the trick.

Cheers,
Wim