Ryan's Blog

Latex cline

Posted in latex by ryanlayer on October 5, 2009

\cline

\cline{i-j} The \cline command draws horizontal lines across the columns specified, beginning in column i and ending in column j, which are identified in the mandatory argument. It is used in the tabular and array environment. Two (or more) successive \cline commands draw lines in the same vertical position. Typically, \cline commands are placed after a \ (line breadk) command so that they separate items on two lines; they do not, however, need a line break command afterwards. \begin{tabular}{|r|l|} \hline 7C0 & hexadecimal \ 3700 & octal \ \cline{2-2} 11111000000 & binary \ \hline \hline 1984 & decimal \ \hline \end{tabular} produces this output
Advertisements
Tagged with: , ,

One Response

Subscribe to comments with RSS.

  1. Marco van Hulten said, on August 10, 2014 at 6:04 am

    Thanks, this is a useful example of the \cline command.

    However, there should be a double backslashes (\\) at end of line.

    For correct/pretty display of tables I suggest using the booktabs package. There one can use \cmidrule which has a similar syntax as \cline (but with some more optional parameters).


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: