10 #include "art/Utilities/ToolMacros.h"
16 namespace ShowerRecoTools {
39 , fPFParticleLabel(pset.
get<art::InputTag>(
"PFParticleLabel"))
40 , fVerbose(pset.
get<int>(
"Verbose"))
41 , fShowerPCAInputLabel(pset.
get<
std::string>(
"ShowerPCAInputLabel"))
42 , fShowerLengthOutputLabel(pset.
get<
std::string>(
"ShowerLengthOutputLabel"))
43 , fShowerOpeningAngleOutputLabel(pset.
get<
std::string>(
"ShowerOpeningAngleOutputLabel"))
44 , fNSigma(pset.
get<float>(
"NSigma"))
55 mf::LogError(
"ShowerPCAEigenvalueLength") <<
"PCA not set, returning " << std::endl;
72 double primaryEigenValue = (eigenValues)[0];
73 double ShowerLength = std::sqrt(primaryEigenValue) * 2 *
fNSigma;
74 double ShowerLengthError = -999;
77 double secondaryEigenValue = (eigenValues)[1];
78 double ShowerWidth = std::sqrt(secondaryEigenValue) * 2 *
fNSigma;
80 double ShowerAngle = std::atan(ShowerWidth / ShowerLength);
81 double ShowerAngleError = -999;
double std(const std::vector< short > &wf, const double ped_mean, size_t start, size_t nsample)
const double * getEigenValues() const
void SetElement(T &dataproduct, const std::string &Name, bool checktag=false)
bool CheckElement(const std::string &Name) const
int GetElement(const std::string &Name, T &Element) const