# TMVA, BDT, Rank Variable : Variable Importance nan

**URL:** <https://root-forum.cern.ch/t/tmva-bdt-rank-variable-variable-importance-nan/22348>\
**Category:** TMVA\
**Created:** [December 12, 2016, 9:34am UTC](https://root-forum.cern.ch/t/tmva-bdt-rank-variable-variable-importance-nan/22348 "2016-12-12T09:34:32Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![kostas\_pikounis](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/k/c0e974/32.png) [@kostas\_pikounis](https://root-forum.cern.ch/u/kostas_pikounis)\
**Post date:** [December 12, 2016, 9:34am UTC](https://root-forum.cern.ch/t/tmva-bdt-rank-variable-variable-importance-nan/22348/1 "2016-12-12T09:34:32Z")

</div>

Dear experts,

I face a problem with the raking of my variables in a BDT and any help would be very much appreciated!

In some of the configurations I tried this is what I see [1] and I would like to understand why I get “nan”.  
(while in other configurations I get values for the rank of the variables). Do you think that I can trust those configurations for which I get “nan” in the ranking, or I should just discard them?  
Also in these configurations the Kolmogorov-Smirnov test is not 0, and the separation of signal/ background is quite nice!  
Please note that although all the variables are doubles, the : Border\_accepted, Sec\_str\_accepted, Extra\_new\_accepted are having a boolean behaviour, so they are either 1, or 0.

The configuration of this BDT is [2].

thank you very much in advance,  
Kostas

[1]  
— BDT3 : Ranking result (top variable is best ranked)  
— BDT3 : ----------------------------------------------------  
— BDT3 : Rank : Variable : Variable Importance  
— BDT3 : ----------------------------------------------------  
— BDT3 : 1 : Border\_accepted : -nan  
— BDT3 : 2 : Sec\_str\_accepted : -nan  
— BDT3 : 3 : Extra\_new\_accepted : -nan  
— BDT3 : 4 : Oms3 : -nan  
— BDT3 : 5 : Oms3\_in\_coinc : -nan  
— BDT3 : 6 : Oms3\_with\_angular : -nan  
— BDT3 : 7 : Tot\_beh\_vtx : -nan  
— BDT3 : 8 : Oms3\_beh\_vtx : -nan  
— BDT3 : 9 : Ratio\_tot : -nan  
— BDT3 : 10 : Ratio\_pulses : -nan  
— BDT3 : ----------------------------------------------------

[2]  
factory-\>BookMethod( TMVA::Types::kBDT, “BDT3”,"!H:!V:NTrees=900:MinNodeSize=0.5%:MaxDepth=4:BoostType=AdaBoost:AdaBoostBeta=0.5:UseBaggedBoost:BaggedSampleFraction=0.1:SeparationType=GiniIndex:nCuts=18" );

---

<div class="post-metadata">

**Author:** ![sergei](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/s/e495f1/32.png) [@sergei](https://root-forum.cern.ch/u/sergei)\
**Post date:** [December 12, 2016, 10:38am UTC](https://root-forum.cern.ch/t/tmva-bdt-rank-variable-variable-importance-nan/22348/2 "2016-12-12T10:38:24Z")

</div>

Hi Kostas,

You shouldn’t ignore the nan’s. I suggest that you post this question to the TMVA users forum:

[sourceforge.net/p/tmva/mailman/tmva-users/](https://sourceforge.net/p/tmva/mailman/tmva-users/)

Cheers,

Sergei

---

<div class="post-metadata">

**Author:** ![kostas\_pikounis](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/k/c0e974/32.png) [@kostas\_pikounis](https://root-forum.cern.ch/u/kostas_pikounis)\
**Post date:** [December 12, 2016, 11:02am UTC](https://root-forum.cern.ch/t/tmva-bdt-rank-variable-variable-importance-nan/22348/3 "2016-12-12T11:02:10Z")

</div>

Dear Sergei,

Thank you for your reply!  
I have already sent an email to the tmva-users mailing list at the 5 of December (so it is already posted to the link you mentioned) but I didn’t have any reply yet, so I tried this, more general, forum.

Cheers,  
Kostas
