# Could I set a few groups of parameters combination in one code script?

**URL:** <https://root-forum.cern.ch/t/could-i-set-a-few-groups-of-parameters-combination-in-one-code-script/46327>\
**Category:** TMVA\
**Created:** [August 17, 2021, 3:12am UTC](https://root-forum.cern.ch/t/could-i-set-a-few-groups-of-parameters-combination-in-one-code-script/46327 "2021-08-17T03:12:48Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![melodynk](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/m/ba9def/32.png) [@melodynk](https://root-forum.cern.ch/u/melodynk)\
**Post date:** [August 17, 2021, 3:12am UTC](https://root-forum.cern.ch/t/could-i-set-a-few-groups-of-parameters-combination-in-one-code-script/46327/1 "2021-08-17T03:12:48Z")

</div>

Hi，all  
I come across a practical problems，that when I would like to try different paramter values in BDT algorithm（such as setting the maxdepth between 5~20）I have to run the code many times when I change the maxdepth value one by one.I wonder there is a directly way to set a few groups of parameters combination in one code script.And after once running I could obtain all the results conviniently.Thanks so much!!

---

<div class="post-metadata">

**Author:** ![moneta](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/moneta/32/19423_2.png) [@moneta](https://root-forum.cern.ch/u/moneta)\
**Post date:** [August 18, 2021, 11:39am UTC](https://root-forum.cern.ch/t/could-i-set-a-few-groups-of-parameters-combination-in-one-code-script/46327/2 "2021-08-18T11:39:26Z")

</div>

Hi,

There is something foreseen in MethodBDT in the function `MethodBDT::OptimizeTuningParameters`, see ([ROOT: TMVA::MethodBDT Class Reference](https://root.cern.ch/doc/master/classTMVA_1_1MethodBDT.html#a5b222cca3c54e1d315d64bc45bba23aa))  
The function can be used also with the class `HyperParameterOptimization` ([ROOT: TMVA::HyperParameterOptimisation Class Reference](https://root.cern.ch/doc/master/classTMVA_1_1HyperParameterOptimisation.html))

This is not well documented and still experimental .The parameters that are changed and their ranges are hard-coded in the implementation of `MethodBDT::OptimizeTuningParameters`.

Lorenzo
