<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><title>R: A formatter for 'allPairs'. This one formats to LaTeX.</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link rel="stylesheet" type="text/css" href="R.css" />
</head><body>

<table width="100%" summary="page for formatter.latex"><tr><td>formatter.latex</td><td style="text-align: right;">R Documentation</td></tr></table>

<h2>A formatter for <code>allPairs</code>. This one formats to LaTeX.</h2>

<h3>Description</h3>

<p>A formatter for <code>allPairs</code>. This one formats to LaTeX.
</p>


<h3>Usage</h3>

<pre>
formatter.latex(what, x, direction = 1)
</pre>


<h3>Arguments</h3>

<table summary="R argblock">
<tr valign="top"><td><code>what</code></td>
<td>
<p>[character] What type of data is <code>x</code>.</p>
</td></tr>
<tr valign="top"><td><code>x</code></td>
<td>
<p>The object to be formatted.</p>
</td></tr>
<tr valign="top"><td><code>direction</code></td>
<td>
<p>[integer] If 1, correspondences are in the order Language1 &gt; Language2 (&quot;x yields y&quot;). If 2, the order is Language2 &lt; Language1 (&quot;y originates from x&quot;). Defaults to 1.</p>
</td></tr>
</table>


<h3>Value</h3>

<p>[character] Formatted x.
</p>


<h3>Examples</h3>

<pre>
# prepare sample dataset
fTrans &lt;- system.file ("extdata", "trans-common.tsv", package="soundcorrs")
fData &lt;- system.file ("extdata", "data-capitals.tsv", package="soundcorrs")
tmp.ger &lt;- read.soundcorrs (fData, "German", "ALIGNED.German", fTrans)
tmp.pol &lt;- read.soundcorrs (fData, "Polish", "ALIGNED.Polish", fTrans)
dataset &lt;- merge (tmp.ger, tmp.pol)
# run allPairs
allPairs (dataset, unit="o", formatter=formatter.latex)
</pre>


</body></html>
