Skip to content

Commit e85ac0e

Browse files
committed
some cleanup, conflict fixes, squashes, re-dos
1 parent bbf3b57 commit e85ac0e

File tree

3 files changed

+86
-51
lines changed

3 files changed

+86
-51
lines changed

doc/documentation.rst

Lines changed: 48 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ Documentation of scikit-learn 0.15
88
.. raw:: html
99

1010
<!-- Block section -->
11+
<!-- row -->
1112
<div class="row-fluid">
1213
<div class="span4 box">
1314
<h2><a href="tutorial/basic/tutorial.html">Quick Start</a></h2>
@@ -17,10 +18,10 @@ Documentation of scikit-learn 0.15
1718
</blockquote>
1819
</div>
1920
<div class="span4 box">
20-
<h2><a href="user_guide.html">User Guide</a></h2>
21-
<blockquote>The main documentation. This contains an
22-
in-depth description of all algorithms and how
23-
to apply them.
21+
<h2><a href="developers/index.html">Contributing</a></h2>
22+
<blockquote>Information on how to contribute. This also
23+
contains useful information for advanced users, for example
24+
how to build their own estimators.
2425
</blockquote>
2526
</div>
2627
<div class="span4 box">
@@ -32,69 +33,72 @@ Documentation of scikit-learn 0.15
3233
</div>
3334
</div>
3435

36+
<!-- row -->
3537
<div class="row-fluid">
36-
<div class="span8">
37-
<!-- Documentation overview -->
38+
<!-- Documentation overview -->
3839
<div class="row-fluid">
39-
<div class="span6 box">
40+
<div class="span4 box">
4041
<h2><a href="tutorial/index.html">Tutorial</a></h2>
4142
<blockquote>A tutorial on statistical learning for
4243
data analysis. Contains a more in-depth discussion
4344
of important concepts.
4445
</blockquote>
4546
</div>
46-
<div class="span6 box">
47-
<h2><a href="modules/classes.html">API</a></h2>
48-
<blockquote>The exact API of all functions and classes, as given by the docstrings.
49-
The API documents expected types and allowed features for all functions,
50-
and all parameters available for the algorithms.
51-
</blockquote>
47+
<div class="span4 box">
48+
<h2><a href="user_guide.html">User Guide</a></h2>
49+
<blockquote>The main documentation. This contains an
50+
in-depth description of all algorithms and how
51+
to apply them.
52+
</blockquote>
5253
</div>
53-
54-
<!-- row -->
55-
</div>
56-
57-
<div class="row-fluid">
58-
<div class="span6 box">
59-
<h2><a href="developers/index.html">Contributing</a></h2>
60-
<blockquote>Information on how to contribute. This also
61-
contains useful information for advanced users, for example
62-
how to build their own estimators.
63-
</blockquote>
64-
</div>
65-
<div class="span6 box">
66-
<h2><a href="presentations.html">Additional Resources</a></h2>
54+
<div class="span4 box">
55+
<h2><a href="presentations.html">Additional Resources</a></h2>
6756
<blockquote>Talks given, slide-sets and other information relevant to scikit-learn.
6857
</blockquote>
69-
</div>
58+
</div>
7059
<!-- row -->
7160
</div>
61+
</div>
7262

73-
<!-- doc overview -->
63+
<!-- row -->
64+
<div class="row-fluid">
65+
<div class="span4 box">
66+
<h2><a href="tutorial/text_analytics/working_with_text_data.html">Text Analysis Tutorial</a></h2>
67+
<blockquote>This tutorial explores an application of machine learning, namely, Text-analysis.
68+
The goal of this guide is to utilize some of the main scikit-learn tools in order to analyze
69+
a collection of text documents.
70+
</blockquote>
7471
</div>
75-
76-
<!-- doc versions -->
77-
72+
<div class="span4 box">
73+
<h2><a href="modules/classes.html">API</a></h2>
74+
<blockquote>The exact API of all functions and classes, as given by the docstrings.
75+
The API documents expected types and allowed features for all functions,
76+
and all parameters available for the algorithms.
77+
</blockquote>
78+
</div>
79+
<!-- doc versions -->
7880
<div class="span4 box">
7981
<h2>Other Versions</h2>
8082
<ul>
8183
<li><a href="http://scikit-learn.org/0.14/user_guide.html">scikit-learn 0.14 (stable)</a></li>
8284
<li>scikit-learn 0.15 (development)</li>
83-
8485
<li><a href="http://scikit-learn.org/0.13/user_guide.html">scikit-learn 0.13</a></li>
8586
<li><a href="http://scikit-learn.org/0.12/user_guide.html">scikit-learn 0.12</a></li>
8687
<li><a href="http://scikit-learn.org/0.11/user_guide.html">scikit-learn 0.11</a></li>
87-
<li><a href="http://scikit-learn.org/0.10/user_guide.html">scikit-learn 0.10</a></li>
88-
<li><a href="http://scikit-learn.org/0.9/user_guide.html">scikit-learn 0.9</a></li>
89-
<li><a href="http://scikit-learn.org/0.8/user_guide.html">scikit-learn 0.8</a></li>
90-
<li><a href="http://scikit-learn.org/0.7/user_guide.html">scikit-learn 0.7</a></li>
91-
<li><a href="http://scikit-learn.org/0.6/user_guide.html">scikit-learn 0.6</a></li>
92-
<li><a href="http://scikit-learn.org/0.5/user_guide.html">scikit-learn 0.5</a></li>
88+
<li id="other-versions">Older versions
89+
<a class="btn dropdown-toggle" data-toggle="dropdown">
90+
<span class="caret"></span>
91+
</a>
92+
<ul class="dropdown-menu">
93+
<li><a href="http://scikit-learn.org/0.10/user_guide.html">scikit-learn 0.10</a></li>
94+
<li><a href="http://scikit-learn.org/0.9/user_guide.html">scikit-learn 0.9</a></li>
95+
<li><a href="http://scikit-learn.org/0.8/user_guide.html">scikit-learn 0.8</a></li>
96+
<li><a href="http://scikit-learn.org/0.7/user_guide.html">scikit-learn 0.7</a></li>
97+
<li><a href="http://scikit-learn.org/0.6/user_guide.html">scikit-learn 0.6</a></li>
98+
<li><a href="http://scikit-learn.org/0.5/user_guide.html">scikit-learn 0.5</a></li>
99+
</ul>
100+
</li>
93101
</ul>
94-
95102
</div>
96-
97-
98-
<!-- row -->
99103
</div>
100-
</div>
104+

doc/themes/scikit-learn/static/nature.css_t

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1110,6 +1110,35 @@ a.btn.dropdown-toggle, a.btn.dropdown-toggle:hover{
11101110
vertical-align: baseline;
11111111
}
11121112

1113+
li#other-versions {
1114+
position: absolute;
1115+
left: inherit;
1116+
right: inherit;
1117+
top: inherit;
1118+
}
1119+
1120+
#other-versions a.btn.dropdown-toggle {
1121+
margin-left: 0.5em;
1122+
padding: 4px 6px 4px 11px;
1123+
}
1124+
1125+
#other-versions .caret {
1126+
border-left: 5px solid transparent;
1127+
border-right: 6px solid transparent;
1128+
border-bottom: 8px solid black;
1129+
border-top: 0px;
1130+
margin-right: 5px;
1131+
margin-top: 0px;
1132+
vertical-align: middle;
1133+
}
1134+
1135+
#other-versions .dropdown-menu {
1136+
position: absolute;
1137+
right: -60%;
1138+
top: -805%;
1139+
left: initial;
1140+
}
1141+
11131142
.navbar .btn, .navbar .open>.btn, .navbar .btn:hover{
11141143
display: inline-block;
11151144
padding: 4px 12px;

doc/tutorial/text_analytics/working_with_text_data.rst

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -357,18 +357,20 @@ analysis of the results::
357357
... target_names=twenty_test.target_names)
358358
... # doctest: +NORMALIZE_WHITESPACE
359359
precision recall f1-score support
360-
alt.atheism 0.93 0.82 0.87 319
361-
comp.graphics 0.88 0.98 0.93 389
360+
<BLANKLINE>
361+
alt.atheism 0.94 0.82 0.87 319
362+
comp.graphics 0.88 0.98 0.92 389
362363
sci.med 0.95 0.89 0.92 396
363364
soc.religion.christian 0.90 0.95 0.92 398
364-
avg / total 0.91 0.91 0.91 1502
365-
365+
<BLANKLINE>
366+
avg / total 0.92 0.91 0.91 1502
367+
<BLANKLINE>
366368

367369
>>> metrics.confusion_matrix(twenty_test.target, predicted)
368370
array([[261, 10, 12, 36],
369371
[ 5, 380, 2, 2],
370-
[ 7, 33, 352, 4],
371-
[ 7, 9, 4, 378]])
372+
[ 7, 32, 353, 4],
373+
[ 6, 11, 4, 377]])
372374

373375
As expected the confusion matrix shows that posts from the newsgroups
374376
on atheism and christian are more often confused for one another than
@@ -448,7 +450,7 @@ we can do::
448450
vect__ngram_range: (1, 1)
449451

450452
>>> score # doctest: +ELLIPSIS
451-
0.910...
453+
0.902...
452454

453455
.. note:
454456

0 commit comments

Comments
 (0)