Hi Sebastian,
I actually worked out how to do this on my own. At least I think I did, I may have missed something! Anyway if I do the following (Note that in my first post the code wouldn’t have worked anyway because all the RooRealVars had mean as their identifier!) :
[code]RooRealVar var(“var”, “var”, 0.5, 0, 1);
RooRealVar mean(“mean”, “mean”, 0.5, 0, 1);
RooRealVar sigma(“sigma”, “sigma”, 0.1, 0, 1);
RooRealVar anotherSigma(“anotherSigma”, “anotherSigma”, 0.2, 0, 1);
RooGaussian gaussMod(“gaussMod”, “Gaussian model”, var, mean, sigma);
gaussMod.Print(“v”);
anotherSigma.setAttribute(“ORIGNAME:sigma”, true);
gaussMod->redirectServers(RooArgList(anotherSigma), false, true);
gaussMod.Print(“v”);[/code]
Then I see:
[quote]— RooAbsArg —
Value State: DIRTY
Shape State: DIRTY
Attributes:
Address: 0x101857e00
Clients:
Servers:
(0x1018e8000,V-) RooRealVar::var “var”
(0x101968a00,V-) RooRealVar::mean “mean”
(0x101969000,V-) RooRealVar::sigma "sigma"
Proxies:
x -> var
mean -> mean
sigma -> sigma
— RooAbsReal —
Plot label is “gaussMod”
— RooAbsPdf —
Cached value = 0
— RooAbsArg —
Value State: DIRTY
Shape State: DIRTY
Attributes:
Address: 0x101857e00
Clients:
Servers:
(0x1018e8000,V-) RooRealVar::var “var”
(0x101968a00,V-) RooRealVar::mean “mean”
(0x101969600,V-) RooRealVar::anotherSigma "anotherSigma"
Proxies:
x -> var
mean -> mean
sigma -> anotherSigma
— RooAbsReal —
Plot label is “gaussMod”
— RooAbsPdf —
Cached value = 0[/quote]
Hope that helps.
Cheers,
Hugh