PageRenderTime 110ms CodeModel.GetById 71ms app.highlight 27ms RepoModel.GetById 1ms app.codeStats 1ms

/doc/tagger.tagger.Tagger-class.html

http://github.com/apresta/tagger
HTML | 253 lines | 213 code | 19 blank | 21 comment | 0 complexity | 01cd215539373cdd63226116e6858900 MD5 | raw file
  1<?xml version="1.0" encoding="ascii"?>
  2<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  3          "DTD/xhtml1-transitional.dtd">
  4<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
  5<head>
  6  <title>tagger.tagger.Tagger</title>
  7  <link rel="stylesheet" href="epydoc.css" type="text/css" />
  8  <script type="text/javascript" src="epydoc.js"></script>
  9</head>
 10
 11<body bgcolor="white" text="black" link="blue" vlink="#204080"
 12      alink="#204080">
 13<!-- ==================== NAVIGATION BAR ==================== -->
 14<table class="navbar" border="0" width="100%" cellpadding="0"
 15       bgcolor="#a0c0ff" cellspacing="0">
 16  <tr valign="middle">
 17
 18  <!-- Tree link -->
 19      <th>&nbsp;&nbsp;&nbsp;<a
 20        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>
 21
 22  <!-- Index link -->
 23      <th>&nbsp;&nbsp;&nbsp;<a
 24        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>
 25
 26  <!-- Help link -->
 27      <th>&nbsp;&nbsp;&nbsp;<a
 28        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>
 29
 30  <!-- Project homepage -->
 31      <th class="navbar" align="right" width="100%">
 32        <table border="0" cellpadding="0" cellspacing="0">
 33          <tr><th class="navbar" align="center"
 34            ><a class="navbar" target="_top" href="http://github.com/apresta/tagger">tagger</a></th>
 35          </tr></table></th>
 36  </tr>
 37</table>
 38<table width="100%" cellpadding="0" cellspacing="0">
 39  <tr valign="top">
 40    <td width="100%">
 41      <span class="breadcrumbs">
 42        Package&nbsp;tagger ::
 43        <a href="tagger.tagger-module.html">Module&nbsp;tagger</a> ::
 44        Class&nbsp;Tagger
 45      </span>
 46    </td>
 47    <td>
 48      <table cellpadding="0" cellspacing="0">
 49        <!-- hide/show private -->
 50        <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink"
 51    onclick="toggle_private();">hide&nbsp;private</a>]</span></td></tr>
 52        <tr><td align="right"><span class="options"
 53            >[<a href="frames.html" target="_top">frames</a
 54            >]&nbsp;|&nbsp;<a href="tagger.tagger.Tagger-class.html"
 55            target="_top">no&nbsp;frames</a>]</span></td></tr>
 56      </table>
 57    </td>
 58  </tr>
 59</table>
 60<!-- ==================== CLASS DESCRIPTION ==================== -->
 61<h1 class="epydoc">Class Tagger</h1><p class="nomargin-top"><span class="codelink"><a href="tagger.tagger-pysrc.html#Tagger">source&nbsp;code</a></span></p>
 62<p>Master class for tagging text documents</p>
 63  <p>(this is a simple interface that should allow convenient 
 64  experimentation by using different classes as building blocks)</p>
 65
 66<!-- ==================== INSTANCE METHODS ==================== -->
 67<a name="section-InstanceMethods"></a>
 68<table class="summary" border="1" cellpadding="3"
 69       cellspacing="0" width="100%" bgcolor="white">
 70<tr bgcolor="#70b0f0" class="table-header">
 71  <td colspan="2" class="table-header">
 72    <table border="0" cellpadding="0" cellspacing="0" width="100%">
 73      <tr valign="top">
 74        <td align="left"><span class="table-header">Instance Methods</span></td>
 75        <td align="right" valign="top"
 76         ><span class="options">[<a href="#section-InstanceMethods"
 77         class="privatelink" onclick="toggle_private();"
 78         >hide private</a>]</span></td>
 79      </tr>
 80    </table>
 81  </td>
 82</tr>
 83<tr>
 84    <td width="15%" align="right" valign="top" class="summary">
 85      <span class="summary-type">&nbsp;</span>
 86    </td><td class="summary">
 87      <table width="100%" cellpadding="0" cellspacing="0" border="0">
 88        <tr>
 89          <td><span class="summary-sig"><a href="tagger.tagger.Tagger-class.html#__init__" class="summary-sig-name">__init__</a>(<span class="summary-sig-arg">self</span>,
 90        <span class="summary-sig-arg">reader</span>,
 91        <span class="summary-sig-arg">stemmer</span>,
 92        <span class="summary-sig-arg">rater</span>)</span><br />
 93      Returns:
 94      a new <a href="tagger.tagger.Tagger-class.html" 
 95      class="link">Tagger</a> object</td>
 96          <td align="right" valign="top">
 97            <span class="codelink"><a href="tagger.tagger-pysrc.html#Tagger.__init__">source&nbsp;code</a></span>
 98            
 99          </td>
100        </tr>
101      </table>
102      
103    </td>
104  </tr>
105<tr>
106    <td width="15%" align="right" valign="top" class="summary">
107      <span class="summary-type">&nbsp;</span>
108    </td><td class="summary">
109      <table width="100%" cellpadding="0" cellspacing="0" border="0">
110        <tr>
111          <td><span class="summary-sig"><a href="tagger.tagger.Tagger-class.html#__call__" class="summary-sig-name">__call__</a>(<span class="summary-sig-arg">self</span>,
112        <span class="summary-sig-arg">text</span>,
113        <span class="summary-sig-arg">tags_number</span>=<span class="summary-sig-default">5</span>)</span></td>
114          <td align="right" valign="top">
115            <span class="codelink"><a href="tagger.tagger-pysrc.html#Tagger.__call__">source&nbsp;code</a></span>
116            
117          </td>
118        </tr>
119      </table>
120      
121    </td>
122  </tr>
123</table>
124<!-- ==================== METHOD DETAILS ==================== -->
125<a name="section-MethodDetails"></a>
126<table class="details" border="1" cellpadding="3"
127       cellspacing="0" width="100%" bgcolor="white">
128<tr bgcolor="#70b0f0" class="table-header">
129  <td colspan="2" class="table-header">
130    <table border="0" cellpadding="0" cellspacing="0" width="100%">
131      <tr valign="top">
132        <td align="left"><span class="table-header">Method Details</span></td>
133        <td align="right" valign="top"
134         ><span class="options">[<a href="#section-MethodDetails"
135         class="privatelink" onclick="toggle_private();"
136         >hide private</a>]</span></td>
137      </tr>
138    </table>
139  </td>
140</tr>
141</table>
142<a name="__init__"></a>
143<div>
144<table class="details" border="1" cellpadding="3"
145       cellspacing="0" width="100%" bgcolor="white">
146<tr><td>
147  <table width="100%" cellpadding="0" cellspacing="0" border="0">
148  <tr valign="top"><td>
149  <h3 class="epydoc"><span class="sig"><span class="sig-name">__init__</span>(<span class="sig-arg">self</span>,
150        <span class="sig-arg">reader</span>,
151        <span class="sig-arg">stemmer</span>,
152        <span class="sig-arg">rater</span>)</span>
153    <br /><em class="fname">(Constructor)</em>
154  </h3>
155  </td><td align="right" valign="top"
156    ><span class="codelink"><a href="tagger.tagger-pysrc.html#Tagger.__init__">source&nbsp;code</a></span>&nbsp;
157    </td>
158  </tr></table>
159  
160  
161  <dl class="fields">
162    <dt>Parameters:</dt>
163    <dd><ul class="nomargin-top">
164        <li><strong class="pname"><code>reader</code></strong> - a <a href="tagger.tagger.Reader-class.html" 
165          class="link">Reader</a> object</li>
166        <li><strong class="pname"><code>stemmer</code></strong> - a <a href="tagger.tagger.Stemmer-class.html" 
167          class="link">Stemmer</a> object</li>
168        <li><strong class="pname"><code>rater</code></strong> - a <a href="tagger.tagger.Rater-class.html" class="link">Rater</a>
169          object</li>
170    </ul></dd>
171    <dt>Returns:</dt>
172        <dd>a new <a href="tagger.tagger.Tagger-class.html" 
173          class="link">Tagger</a> object</dd>
174  </dl>
175</td></tr></table>
176</div>
177<a name="__call__"></a>
178<div>
179<table class="details" border="1" cellpadding="3"
180       cellspacing="0" width="100%" bgcolor="white">
181<tr><td>
182  <table width="100%" cellpadding="0" cellspacing="0" border="0">
183  <tr valign="top"><td>
184  <h3 class="epydoc"><span class="sig"><span class="sig-name">__call__</span>(<span class="sig-arg">self</span>,
185        <span class="sig-arg">text</span>,
186        <span class="sig-arg">tags_number</span>=<span class="sig-default">5</span>)</span>
187    <br /><em class="fname">(Call operator)</em>
188  </h3>
189  </td><td align="right" valign="top"
190    ><span class="codelink"><a href="tagger.tagger-pysrc.html#Tagger.__call__">source&nbsp;code</a></span>&nbsp;
191    </td>
192  </tr></table>
193  
194  
195  <dl class="fields">
196    <dt>Parameters:</dt>
197    <dd><ul class="nomargin-top">
198        <li><strong class="pname"><code>text</code></strong> - the string of text to be tagged</li>
199        <li><strong class="pname"><code>tags_number</code></strong> - number of best tags to be returned
200          <p>Returns: a list of (hopefully) relevant tags</p></li>
201    </ul></dd>
202  </dl>
203</td></tr></table>
204</div>
205<br />
206<!-- ==================== NAVIGATION BAR ==================== -->
207<table class="navbar" border="0" width="100%" cellpadding="0"
208       bgcolor="#a0c0ff" cellspacing="0">
209  <tr valign="middle">
210
211  <!-- Tree link -->
212      <th>&nbsp;&nbsp;&nbsp;<a
213        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>
214
215  <!-- Index link -->
216      <th>&nbsp;&nbsp;&nbsp;<a
217        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>
218
219  <!-- Help link -->
220      <th>&nbsp;&nbsp;&nbsp;<a
221        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>
222
223  <!-- Project homepage -->
224      <th class="navbar" align="right" width="100%">
225        <table border="0" cellpadding="0" cellspacing="0">
226          <tr><th class="navbar" align="center"
227            ><a class="navbar" target="_top" href="http://github.com/apresta/tagger">tagger</a></th>
228          </tr></table></th>
229  </tr>
230</table>
231<table border="0" cellpadding="0" cellspacing="0" width="100%%">
232  <tr>
233    <td align="left" class="footer">
234    Generated by Epydoc 3.0.1 on Wed Jun  8 01:57:46 2011
235    </td>
236    <td align="right" class="footer">
237      <a target="mainFrame" href="http://epydoc.sourceforge.net"
238        >http://epydoc.sourceforge.net</a>
239    </td>
240  </tr>
241</table>
242
243<script type="text/javascript">
244  <!--
245  // Private objects are initially displayed (because if
246  // javascript is turned off then we want them to be
247  // visible); but by default, we want to hide them.  So hide
248  // them unless we have a cookie that says to show them.
249  checkCookie();
250  // -->
251</script>
252</body>
253</html>