Changeset 7408 for trunk/MagicSoft/Mars/mhflux
- Timestamp:
- 11/18/05 16:55:22 (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mhflux/MMcSpectrumWeight.cc
r7174 r7408 61 61 // 62 62 // 63 // If using SetFormula you can specify formulas accepted by TF1, eg: 64 // pow(X, -2.6) 65 // (Rem: all capital (!) 'X' are replaced by the corresponding %s.fEnergy 66 // automatically) 67 // 68 // 63 69 // Input Containers: 64 70 // MMcEvt … … 218 224 TString MMcSpectrumWeight::GetFormulaSpecNew() const 219 225 { 220 return fFormula.IsNull() ? Form("pow(%s.fEnergy, %.3f)", fNameMcEvt.Data(), fNewSlope) : fFormula; 226 TString str = fFormula.IsNull() ? Form("pow(%s.fEnergy, %.3f)", fNameMcEvt.Data(), fNewSlope) : fFormula; 227 if (!fFormula.IsNull()) 228 str.ReplaceAll("X", Form("(%s.fEnergy)", fNameMcEvt.Data())); 229 230 return str; 221 231 } 222 232
Note:
See TracChangeset
for help on using the changeset viewer.