Changed flatten subsample behaviour not working on batch #21
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The flatten subsample implementation with lambda functions was cryptic and was not working in batch mode.
Now it is turned into a simple flag that can be specified in the samples dictionary. If the value is 0 then one recovers the normal behaviour, prepending the sample name to the subsample one. If 1 is specified, the sample name is dropped.
This fix is sufficient and covers all cases as user are free to specify whatever subsample name.
Both local and batch execution have been tested successfully.
Example docs updated.
Note: it was raised some months ago that nuisances could not be applied to only specific subsamples (it was either all of them or none of them). Now it is possible (at least for weight type uncertainties) to compute them only on a set of subsamples. I do not know if this feature was implemented before but it is worth reminding it in this PR.