Michael Patterson
3c22232c4b
Now plots based on the number of features in X
...
In previous commit, I used n_features to set the number of features, and plotted based on that variable. Based on feedback, I removed n_features, and now plotting is based on X.shape[1]. This makes the code general and easy to port. I copied this into an iPython notebook to verify it still outputs the correct graph.
2015-10-11 23:09:39 -07:00
Michael Patterson
0fec61a709
Changed the number of features from 10 to variable
...
I ported this code into my own, and when I tried plotting, I found the number of features was hard coded to 10. By switching to a set variable, the number of features is no longer a magic number, and the code is more readable.
2015-10-11 16:58:41 -07:00
Gilles Louppe
b499743c93
DOC: update examples, use matplotlib.pyplot instead of pylab
2014-02-27 10:22:21 +01:00
ugurthemaster
4640608151
Update plot_forest_importances.py
...
import statement has moved to the top of the file
2014-02-26 10:55:01 +02:00
Stefano Lattarini
67ece78da4
COSMIT various typofixes
...
As suggested by codespell <https://github.com/lucasdemarchi/codespell >
Signed-off-by: Stefano Lattarini <stefano.lattarini@gmail.com>
2013-04-11 21:22:14 +02:00
Gilles Louppe
0b2f92d025
EXAMPLE: compute_importances=True is no longer required (1)
2013-02-08 08:37:00 +01:00
Lars Buitinck
837093df7f
P3K: use print as a function in the examples
...
Also corrected some typos, including two people misspelling their own names :)
2013-02-01 15:04:42 +01:00
Andreas Mueller
713ba6006e
COSMIT pep8
2012-09-04 17:24:01 +01:00
Gilles Louppe
e25fa50f6f
EXAMPLE: plot importances with bars
2012-07-19 11:42:04 +02:00
Andreas Mueller
77f3fecb21
COSMIT pep8
2012-01-28 14:52:10 +01:00
Gilles Louppe
83f693f662
EXAMPLE: Fixed API changes
2011-12-27 17:54:25 +01:00
Gilles Louppe
e78ae4ad0a
COSMIT: examples
2011-12-19 19:06:58 +01:00
Gilles Louppe
8636e32667
ENH: Use extra-trees instead of rf
2011-12-19 19:00:43 +01:00
Gilles Louppe
e50c6003f7
EXAMPLE: Improved plot_forest_importances.py plot
2011-12-19 14:02:43 +01:00
Gilles Louppe
d766775cc6
EXAMPLE: Added examples for feature importances using trees
2011-12-19 13:10:44 +01:00