本文整理汇总了Python中ROOT.RooArgSet.getRealValue方法的典型用法代码示例。如果您正苦于以下问题:Python RooArgSet.getRealValue方法的具体用法?Python RooArgSet.getRealValue怎么用?Python RooArgSet.getRealValue使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ROOT.RooArgSet
的用法示例。
在下文中一共展示了RooArgSet.getRealValue方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: RooArgList
# 需要导入模块: from ROOT import RooArgSet [as 别名]
# 或者: from ROOT.RooArgSet import getRealValue [as 别名]
ampMeasFuncs[ ampMeasNames[ 5 + 2 * bin ] ] = '@{0:d}/([email protected]{0:d})/@2'.format( 4 + 2 * bin )
ampMeasFuncs[ ampMeasNames[ 6 + 2 * bin ] ] = '@{0:d}[email protected]{1:s}'.format( 5 + 2 * bin, '+TMath::TwoPi()'\
if pdfConfig['ambiguityParameters'] else '' )
else :
ampMeasFuncs[ ampMeasNames[5] ] = '@4/([email protected])/@2'
ampMeasFuncs[ ampMeasNames[6] ] = '@[email protected]'
# create fitted parameters and functions
from ROOT import RooFormulaVar
ampMeasList = RooArgList()
ampFuncsList = RooArgList()
ampMeasInds = { }
ampMeas = [ ]
ampFuncs = [ ]
for ampName in ampMeasNames :
ampMeas.append( RooRealVar( ampName + '_meas', ampName + '_meas', parSet.getRealValue(ampName), -1e+30, 1e+30 ) )
ampFuncs.append( RooFormulaVar( ampName + '_func', ampMeasFuncs[ampName], ampPhysList ) )
ampMeasList.add( ampMeas[-1] )
ampFuncsList.add( ampFuncs[-1] )
ampMeasInds[ampName] = parList.index(ampName)
ampMeasSet = RooArgSet(ampMeasList)
# get covariances from likelihood fit
from ROOT import TMatrixDSym
ampMeasCovs = TMatrixDSym(len(ampMeasNames))
for ampIter, ampName in enumerate(ampMeasNames) :
for ampIter1, ampName1 in enumerate(ampMeasNames) :
ampMeasCovs[ampIter][ampIter1] = parCovs[ampMeasInds[ampName]][ampMeasInds[ampName1]]
# determine values of physics parameters
from ROOT import RooDataSet, RooMultiVarGaussian