If you set sample_weight[i] = 2, for the i-th samples. It will
consider that this sample has to be accounted twice in the tree
growing procedure (impurity computation, leaf labelling, …).

Best regards,
Arnaud



> On 26 Apr 2015, at 16:00, Luca Puggini <lucapug...@gmail.com> wrote:
> 
> Ok thanks a lot, a last question.  
> 
> What is the role of sample_weight If I use ExtraTreesClassifier with 
> bootstrap=False (this is the default)?  
> Are they used during the splitting process?  
> 
> On Sat, Apr 25, 2015 at 10:04 PM, Andy <t3k...@gmail.com 
> <mailto:t3k...@gmail.com>> wrote:
> On 04/25/2015 09:18 AM, Luca Puggini wrote:
>> I think it depends by the role of sample weight during the construction of 
>> the forest. 
>> If I set sample_weight = 2 for one of my samples is this equivalent to 
>> duplicate the row in the data?
>> 
> During fitting, yes, during evaluation currently not.
> 
> 
>> On Fri, Apr 24, 2015 at 10:25 PM, Andreas Mueller <t3k...@gmail.com 
>> <mailto:t3k...@gmail.com>> wrote:
>> The roc_auc will not take sample_weights into account if using 
>> cross_val_score.
>> Thinking about it, I'm not sure if this a bug or a feature.
>> Not sure if that was discussed before, I opened an issue:
>> https://github.com/scikit-learn/scikit-learn/issues/4632 
>> <https://github.com/scikit-learn/scikit-learn/issues/4632>
>> 
>> 
>> On 04/24/2015 12:29 PM, Luca Puggini wrote:
>>> Dear all,
>>> 
>>> I am quiet new to  {0,1} classification problems. 
>>> I have an unbalanced dataset and and I am using a RandomForestMethod on it. 
>>> 
>>> To evaluate the performances of my estimator I am using the cross_val_score 
>>> function with the roc_auc metric. 
>>> 
>>> My understanding is that to deal with unbalanced problem I can pass the 
>>> argument sample_weight to the random forest estimator.
>>> 
>>> I do not understand if I should pass the sample_weight parameters also in 
>>> this case or if this will bias the result obtained with roc_auc
>>> 
>>> Is there any common way to do that? Have you any advice?
>>> 
>>> Thanks a lot! 
>>> 
>>> 
>>> ------------------------------------------------------------------------------
>>> One dashboard for servers and applications across Physical-Virtual-Cloud 
>>> Widest out-of-the-box monitoring support with 50+ applications
>>> Performance metrics, stats and reports that give you Actionable Insights
>>> Deep dive visibility with transaction tracing using APM Insight.
>>> http://ad.doubleclick.net/ddm/clk/290420510;117567292;y 
>>> <http://ad.doubleclick.net/ddm/clk/290420510;117567292;y>
>>> 
>>> _______________________________________________
>>> Scikit-learn-general mailing list
>>> Scikit-learn-general@lists.sourceforge.net 
>>> <mailto:Scikit-learn-general@lists.sourceforge.net>
>>> https://lists.sourceforge.net/lists/listinfo/scikit-learn-general 
>>> <https://lists.sourceforge.net/lists/listinfo/scikit-learn-general>
>> 
>> 
>> ------------------------------------------------------------------------------
>> One dashboard for servers and applications across Physical-Virtual-Cloud
>> Widest out-of-the-box monitoring support with 50+ applications
>> Performance metrics, stats and reports that give you Actionable Insights
>> Deep dive visibility with transaction tracing using APM Insight.
>> http://ad.doubleclick.net/ddm/clk/290420510;117567292;y 
>> <http://ad.doubleclick.net/ddm/clk/290420510;117567292;y>
>> _______________________________________________
>> Scikit-learn-general mailing list
>> Scikit-learn-general@lists.sourceforge.net 
>> <mailto:Scikit-learn-general@lists.sourceforge.net>
>> https://lists.sourceforge.net/lists/listinfo/scikit-learn-general 
>> <https://lists.sourceforge.net/lists/listinfo/scikit-learn-general>
>> 
>> 
>> 
>> 
>> ------------------------------------------------------------------------------
>> One dashboard for servers and applications across Physical-Virtual-Cloud 
>> Widest out-of-the-box monitoring support with 50+ applications
>> Performance metrics, stats and reports that give you Actionable Insights
>> Deep dive visibility with transaction tracing using APM Insight.
>> http://ad.doubleclick.net/ddm/clk/290420510;117567292;y 
>> <http://ad.doubleclick.net/ddm/clk/290420510;117567292;y>
>> 
>> _______________________________________________
>> Scikit-learn-general mailing list
>> Scikit-learn-general@lists.sourceforge.net 
>> <mailto:Scikit-learn-general@lists.sourceforge.net>
>> https://lists.sourceforge.net/lists/listinfo/scikit-learn-general 
>> <https://lists.sourceforge.net/lists/listinfo/scikit-learn-general>
> 
> 
> ------------------------------------------------------------------------------
> One dashboard for servers and applications across Physical-Virtual-Cloud
> Widest out-of-the-box monitoring support with 50+ applications
> Performance metrics, stats and reports that give you Actionable Insights
> Deep dive visibility with transaction tracing using APM Insight.
> http://ad.doubleclick.net/ddm/clk/290420510;117567292;y 
> <http://ad.doubleclick.net/ddm/clk/290420510;117567292;y>
> _______________________________________________
> Scikit-learn-general mailing list
> Scikit-learn-general@lists.sourceforge.net 
> <mailto:Scikit-learn-general@lists.sourceforge.net>
> https://lists.sourceforge.net/lists/listinfo/scikit-learn-general 
> <https://lists.sourceforge.net/lists/listinfo/scikit-learn-general>
> 
> 
> ------------------------------------------------------------------------------
> One dashboard for servers and applications across Physical-Virtual-Cloud 
> Widest out-of-the-box monitoring support with 50+ applications
> Performance metrics, stats and reports that give you Actionable Insights
> Deep dive visibility with transaction tracing using APM Insight.
> http://ad.doubleclick.net/ddm/clk/290420510;117567292;y_______________________________________________
> Scikit-learn-general mailing list
> Scikit-learn-general@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/scikit-learn-general

------------------------------------------------------------------------------
One dashboard for servers and applications across Physical-Virtual-Cloud 
Widest out-of-the-box monitoring support with 50+ applications
Performance metrics, stats and reports that give you Actionable Insights
Deep dive visibility with transaction tracing using APM Insight.
http://ad.doubleclick.net/ddm/clk/290420510;117567292;y
_______________________________________________
Scikit-learn-general mailing list
Scikit-learn-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/scikit-learn-general

Reply via email to