start adding CSV like data reading routine with the FileFormat label DAT.
This commit is contained in:
parent
f7bc2aab87
commit
de5763d5cc
@ -549,6 +549,9 @@ void PRunAsymmetry::CalcTheory()
|
||||
*/
|
||||
Bool_t PRunAsymmetry::PrepareData()
|
||||
{
|
||||
if (!fValid)
|
||||
return false;
|
||||
|
||||
// keep the Global block info
|
||||
PMsrGlobalBlock *globalBlock = fMsrInfo->GetMsrGlobal();
|
||||
|
||||
|
@ -587,6 +587,9 @@ void PRunAsymmetryBNMR::CalcTheory()
|
||||
*/
|
||||
Bool_t PRunAsymmetryBNMR::PrepareData()
|
||||
{
|
||||
if (!fValid)
|
||||
return false;
|
||||
|
||||
// keep the Global block info
|
||||
PMsrGlobalBlock *globalBlock = fMsrInfo->GetMsrGlobal();
|
||||
|
||||
|
@ -531,6 +531,9 @@ void PRunAsymmetryRRF::CalcTheory()
|
||||
*/
|
||||
Bool_t PRunAsymmetryRRF::PrepareData()
|
||||
{
|
||||
if (!fValid)
|
||||
return false;
|
||||
|
||||
// keep the Global block info
|
||||
PMsrGlobalBlock *globalBlock = fMsrInfo->GetMsrGlobal();
|
||||
|
||||
|
@ -538,6 +538,8 @@ Bool_t PRunDataHandler::ReadFilesMsr()
|
||||
success = ReadAsciiFile();
|
||||
} else if (!runList->at(i).GetFileFormat(j)->CompareTo("db")) {
|
||||
success = ReadDBFile();
|
||||
} else if (!runList->at(i).GetFileFormat(j)->CompareTo("dat")) {
|
||||
success = ReadDatFile();
|
||||
} else {
|
||||
success = false;
|
||||
}
|
||||
@ -1102,6 +1104,8 @@ Bool_t PRunDataHandler::FileExistsCheck(PMsrRunBlock &runInfo, const UInt_t idx)
|
||||
ext = TString("dat");
|
||||
else if (!runInfo.GetFileFormat(idx)->CompareTo("db"))
|
||||
ext = TString("db");
|
||||
else if (!runInfo.GetFileFormat(idx)->CompareTo("dat"))
|
||||
ext = TString("dat");
|
||||
else
|
||||
success = false;
|
||||
|
||||
@ -1126,6 +1130,7 @@ Bool_t PRunDataHandler::FileExistsCheck(PMsrRunBlock &runInfo, const UInt_t idx)
|
||||
std::cerr << std::endl << ">> MDU-ASCII -> psi mdu ascii file format";
|
||||
std::cerr << std::endl << ">> ASCII -> column like file format";
|
||||
std::cerr << std::endl << ">> DB -> triumf db file \"format\"";
|
||||
std::cerr << std::endl << ">> DAT -> csv like file \"format\" as exported by msr2data.";
|
||||
std::cerr << std::endl;
|
||||
return success;
|
||||
}
|
||||
@ -4345,6 +4350,18 @@ Bool_t PRunDataHandler::ReadDBFile()
|
||||
return success;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
// ReadDBFile (private)
|
||||
//--------------------------------------------------------------------------
|
||||
Bool_t PRunDataHandler::ReadDatFile()
|
||||
{
|
||||
Bool_t success = true;
|
||||
|
||||
std::cerr << "debug> in PRunDataHandler::ReadDatFile(). Not yet implemented..." << std::endl;
|
||||
|
||||
return success;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
// WriteMusrRootFile (private)
|
||||
//--------------------------------------------------------------------------
|
||||
|
@ -458,6 +458,9 @@ Bool_t PRunMuMinus::PrepareData()
|
||||
{
|
||||
Bool_t success = true;
|
||||
|
||||
if (!fValid)
|
||||
return false;
|
||||
|
||||
// keep the Global block info
|
||||
PMsrGlobalBlock *globalBlock = fMsrInfo->GetMsrGlobal();
|
||||
|
||||
|
@ -198,6 +198,9 @@ Bool_t PRunNonMusr::PrepareData()
|
||||
{
|
||||
Bool_t success = true;
|
||||
|
||||
if (!fValid)
|
||||
return false;
|
||||
|
||||
if (fRunInfo->GetRunNameSize() > 1) { // ADDRUN present which is not supported for NonMusr
|
||||
std::cerr << std::endl << ">> PRunNonMusr::PrepareData(): **WARNING** ADDRUN NOT SUPPORTED FOR THIS FIT TYPE, WILL IGNORE IT." << std::endl;
|
||||
}
|
||||
|
@ -700,6 +700,9 @@ Bool_t PRunSingleHisto::PrepareData()
|
||||
{
|
||||
Bool_t success = true;
|
||||
|
||||
if (!fValid)
|
||||
return false;
|
||||
|
||||
// keep the Global block info
|
||||
PMsrGlobalBlock *globalBlock = fMsrInfo->GetMsrGlobal();
|
||||
|
||||
|
@ -431,6 +431,9 @@ Bool_t PRunSingleHistoRRF::PrepareData()
|
||||
{
|
||||
Bool_t success = true;
|
||||
|
||||
if (!fValid)
|
||||
return false;
|
||||
|
||||
// keep the Global block info
|
||||
PMsrGlobalBlock *globalBlock = fMsrInfo->GetMsrGlobal();
|
||||
|
||||
|
@ -89,6 +89,7 @@ class PRunDataHandler
|
||||
virtual Bool_t ReadMduAsciiFile();
|
||||
virtual Bool_t ReadAsciiFile();
|
||||
virtual Bool_t ReadDBFile();
|
||||
virtual Bool_t ReadDatFile();
|
||||
|
||||
virtual Bool_t WriteMusrRootFile(TString fln="");
|
||||
virtual Bool_t WriteRootFile(TString fln="");
|
||||
|
Loading…
x
Reference in New Issue
Block a user