PageRenderTime 40ms CodeModel.GetById 1ms app.highlight 30ms RepoModel.GetById 2ms app.codeStats 0ms

/doc/tagger.tagger.Tag-class.html

http://github.com/apresta/tagger
HTML | 285 lines | 241 code | 23 blank | 21 comment | 0 complexity | 801df1247fbcc644d916614bc04957a0 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.Tag</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;Tag
 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.Tag-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 Tag</h1><p class="nomargin-top"><span class="codelink"><a href="tagger.tagger-pysrc.html#Tag">source&nbsp;code</a></span></p>
 62<center>
 63<center>  <map id="class_hierarchy_for_tag" name="class_hierarchy_for_tag">
 64<area shape="rect" id="node1" href="tagger.tagger.MultiTag-class.html" title="MultiTag" alt="" coords="5,61,88,88"/>
 65<area shape="rect" id="node2" href="tagger.tagger.Tag-class.html" title="Tag" alt="" coords="23,5,71,32"/>
 66</map>
 67  <img src="class_hierarchy_for_tag.gif" alt='' usemap="#class_hierarchy_for_tag" ismap="ismap" class="graph-without-title" />
 68</center>
 69</center>
 70<hr />
 71<p>General class for tags (small units of text)</p>
 72
 73<!-- ==================== INSTANCE METHODS ==================== -->
 74<a name="section-InstanceMethods"></a>
 75<table class="summary" border="1" cellpadding="3"
 76       cellspacing="0" width="100%" bgcolor="white">
 77<tr bgcolor="#70b0f0" class="table-header">
 78  <td colspan="2" class="table-header">
 79    <table border="0" cellpadding="0" cellspacing="0" width="100%">
 80      <tr valign="top">
 81        <td align="left"><span class="table-header">Instance Methods</span></td>
 82        <td align="right" valign="top"
 83         ><span class="options">[<a href="#section-InstanceMethods"
 84         class="privatelink" onclick="toggle_private();"
 85         >hide private</a>]</span></td>
 86      </tr>
 87    </table>
 88  </td>
 89</tr>
 90<tr>
 91    <td width="15%" align="right" valign="top" class="summary">
 92      <span class="summary-type">&nbsp;</span>
 93    </td><td class="summary">
 94      <table width="100%" cellpadding="0" cellspacing="0" border="0">
 95        <tr>
 96          <td><span class="summary-sig"><a href="tagger.tagger.Tag-class.html#__init__" class="summary-sig-name">__init__</a>(<span class="summary-sig-arg">self</span>,
 97        <span class="summary-sig-arg">string</span>,
 98        <span class="summary-sig-arg">stem</span>=<span class="summary-sig-default">None</span>,
 99        <span class="summary-sig-arg">rating</span>=<span class="summary-sig-default">1.0</span>,
100        <span class="summary-sig-arg">proper</span>=<span class="summary-sig-default">False</span>,
101        <span class="summary-sig-arg">terminal</span>=<span class="summary-sig-default">False</span>)</span><br />
102      Returns:
103      a new <a href="tagger.tagger.Tag-class.html" class="link">Tag</a> 
104      object</td>
105          <td align="right" valign="top">
106            <span class="codelink"><a href="tagger.tagger-pysrc.html#Tag.__init__">source&nbsp;code</a></span>
107            
108          </td>
109        </tr>
110      </table>
111      
112    </td>
113  </tr>
114<tr>
115    <td width="15%" align="right" valign="top" class="summary">
116      <span class="summary-type">&nbsp;</span>
117    </td><td class="summary">
118      <table width="100%" cellpadding="0" cellspacing="0" border="0">
119        <tr>
120          <td><span class="summary-sig"><a name="__eq__"></a><span class="summary-sig-name">__eq__</span>(<span class="summary-sig-arg">self</span>,
121        <span class="summary-sig-arg">other</span>)</span></td>
122          <td align="right" valign="top">
123            <span class="codelink"><a href="tagger.tagger-pysrc.html#Tag.__eq__">source&nbsp;code</a></span>
124            
125          </td>
126        </tr>
127      </table>
128      
129    </td>
130  </tr>
131<tr>
132    <td width="15%" align="right" valign="top" class="summary">
133      <span class="summary-type">&nbsp;</span>
134    </td><td class="summary">
135      <table width="100%" cellpadding="0" cellspacing="0" border="0">
136        <tr>
137          <td><span class="summary-sig"><a name="__repr__"></a><span class="summary-sig-name">__repr__</span>(<span class="summary-sig-arg">self</span>)</span></td>
138          <td align="right" valign="top">
139            <span class="codelink"><a href="tagger.tagger-pysrc.html#Tag.__repr__">source&nbsp;code</a></span>
140            
141          </td>
142        </tr>
143      </table>
144      
145    </td>
146  </tr>
147<tr>
148    <td width="15%" align="right" valign="top" class="summary">
149      <span class="summary-type">&nbsp;</span>
150    </td><td class="summary">
151      <table width="100%" cellpadding="0" cellspacing="0" border="0">
152        <tr>
153          <td><span class="summary-sig"><a name="__lt__"></a><span class="summary-sig-name">__lt__</span>(<span class="summary-sig-arg">self</span>,
154        <span class="summary-sig-arg">other</span>)</span></td>
155          <td align="right" valign="top">
156            <span class="codelink"><a href="tagger.tagger-pysrc.html#Tag.__lt__">source&nbsp;code</a></span>
157            
158          </td>
159        </tr>
160      </table>
161      
162    </td>
163  </tr>
164<tr>
165    <td width="15%" align="right" valign="top" class="summary">
166      <span class="summary-type">&nbsp;</span>
167    </td><td class="summary">
168      <table width="100%" cellpadding="0" cellspacing="0" border="0">
169        <tr>
170          <td><span class="summary-sig"><a name="__hash__"></a><span class="summary-sig-name">__hash__</span>(<span class="summary-sig-arg">self</span>)</span></td>
171          <td align="right" valign="top">
172            <span class="codelink"><a href="tagger.tagger-pysrc.html#Tag.__hash__">source&nbsp;code</a></span>
173            
174          </td>
175        </tr>
176      </table>
177      
178    </td>
179  </tr>
180</table>
181<!-- ==================== METHOD DETAILS ==================== -->
182<a name="section-MethodDetails"></a>
183<table class="details" border="1" cellpadding="3"
184       cellspacing="0" width="100%" bgcolor="white">
185<tr bgcolor="#70b0f0" class="table-header">
186  <td colspan="2" class="table-header">
187    <table border="0" cellpadding="0" cellspacing="0" width="100%">
188      <tr valign="top">
189        <td align="left"><span class="table-header">Method Details</span></td>
190        <td align="right" valign="top"
191         ><span class="options">[<a href="#section-MethodDetails"
192         class="privatelink" onclick="toggle_private();"
193         >hide private</a>]</span></td>
194      </tr>
195    </table>
196  </td>
197</tr>
198</table>
199<a name="__init__"></a>
200<div>
201<table class="details" border="1" cellpadding="3"
202       cellspacing="0" width="100%" bgcolor="white">
203<tr><td>
204  <table width="100%" cellpadding="0" cellspacing="0" border="0">
205  <tr valign="top"><td>
206  <h3 class="epydoc"><span class="sig"><span class="sig-name">__init__</span>(<span class="sig-arg">self</span>,
207        <span class="sig-arg">string</span>,
208        <span class="sig-arg">stem</span>=<span class="sig-default">None</span>,
209        <span class="sig-arg">rating</span>=<span class="sig-default">1.0</span>,
210        <span class="sig-arg">proper</span>=<span class="sig-default">False</span>,
211        <span class="sig-arg">terminal</span>=<span class="sig-default">False</span>)</span>
212    <br /><em class="fname">(Constructor)</em>
213  </h3>
214  </td><td align="right" valign="top"
215    ><span class="codelink"><a href="tagger.tagger-pysrc.html#Tag.__init__">source&nbsp;code</a></span>&nbsp;
216    </td>
217  </tr></table>
218  
219  
220  <dl class="fields">
221    <dt>Parameters:</dt>
222    <dd><ul class="nomargin-top">
223        <li><strong class="pname"><code>string</code></strong> - the actual representation of the tag</li>
224        <li><strong class="pname"><code>stem</code></strong> - the internal (usually stemmed) representation; tags with the same
225          stem are regarded as equal</li>
226        <li><strong class="pname"><code>rating</code></strong> - a measure of the tag's relevance in the interval [0,1]</li>
227        <li><strong class="pname"><code>proper</code></strong> - whether the tag is a proper noun</li>
228        <li><strong class="pname"><code>terminal</code></strong> - set to True if the tag is at the end of a phrase (or anyway it 
229          cannot be logically merged to the following one)</li>
230    </ul></dd>
231    <dt>Returns:</dt>
232        <dd>a new <a href="tagger.tagger.Tag-class.html" class="link">Tag</a>
233          object</dd>
234  </dl>
235</td></tr></table>
236</div>
237<br />
238<!-- ==================== NAVIGATION BAR ==================== -->
239<table class="navbar" border="0" width="100%" cellpadding="0"
240       bgcolor="#a0c0ff" cellspacing="0">
241  <tr valign="middle">
242
243  <!-- Tree link -->
244      <th>&nbsp;&nbsp;&nbsp;<a
245        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>
246
247  <!-- Index link -->
248      <th>&nbsp;&nbsp;&nbsp;<a
249        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>
250
251  <!-- Help link -->
252      <th>&nbsp;&nbsp;&nbsp;<a
253        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>
254
255  <!-- Project homepage -->
256      <th class="navbar" align="right" width="100%">
257        <table border="0" cellpadding="0" cellspacing="0">
258          <tr><th class="navbar" align="center"
259            ><a class="navbar" target="_top" href="http://github.com/apresta/tagger">tagger</a></th>
260          </tr></table></th>
261  </tr>
262</table>
263<table border="0" cellpadding="0" cellspacing="0" width="100%%">
264  <tr>
265    <td align="left" class="footer">
266    Generated by Epydoc 3.0.1 on Wed Jun  8 01:57:46 2011
267    </td>
268    <td align="right" class="footer">
269      <a target="mainFrame" href="http://epydoc.sourceforge.net"
270        >http://epydoc.sourceforge.net</a>
271    </td>
272  </tr>
273</table>
274
275<script type="text/javascript">
276  <!--
277  // Private objects are initially displayed (because if
278  // javascript is turned off then we want them to be
279  // visible); but by default, we want to hide them.  So hide
280  // them unless we have a cookie that says to show them.
281  checkCookie();
282  // -->
283</script>
284</body>
285</html>