I have done a simultaneous fit and for changing the parameters, I am trying to pick many text files and save each of the plot corresponding to each .txt file. But, only the plot that occurs last in the code is saved while the others are not saved. Will you please have a look ?
If the “output…” TStrings are supposed to point to different folders, this doesn’t work, as all the TStrings in the first line (kk_d01,…) are empty, so all “output…” TStrings are the same.
(also, make sure outputpath and fname have values at this point!)
Thank you for your responses. I have managed to solve all the problems with the code and I have added almost all the functionalities except one. Here’'s the macro that I am using: asymmetry_all_params.C (40.6 KB)
Is there a way to put the condition so as to save the plots only if the fit converges ?
Also, is there a way to submit jobs in parallel for the multiple .txt files that I use.
I don’t know where you are submitting the jobs, so the how depends on the job queuing system, but if the txt files are used independently of each other in the macro, the simplest is to use and process only one of these files in the macro, and run the macro as many times as needed, once for each txt file (maybe giving the file name as argument to the macro), sending each run as separate job.
Thanks a lot @dastudillo.
For the fitresult, what you are suggesting actually works. However, I think, there is still a problem with this. which I try to explain below:
For a good fit, what I check is FROM MIGRAD STATUS=CONVERGED , ERR MATRIX ACCURATE and ERROR MATRIX ACCURATE. So, what I want is to check all the 4 conditions. While the above condition checks only if MIGRAD STATUS=CONVERGED and allows to pass even if ERR MATRIX is not ACCURATE (eg: if ERR MATRIX NOT POS-DEF ).
Is this expected? Can I check All the 4 conditions ?
I have checked that the covQual option in RooFitResult allows us to check the covariance quality. Using this, I can check the status and the error matrix from HESSE and as you have already pointed out, status allows us to check the status fro MIGRAD.
Is there a way to put a constraint so that the results are saved only of the Error Marrix corresponding to MIGRAD should be accurate?