Skip to content
Back to formatted view

Raw Message

Message-ID: <1205259031.21826.2.camel@hades>
Date: 2008-03-11T18:10:31Z
From: Markus Jäntti
Subject: R-Latex question
In-Reply-To: <15980281.post@talk.nabble.com>

On Tue, 2008-03-11 at 10:23 -0700, threshold wrote:
> cat("\hline \n");flush.console()

you need to double the backslashes, as in

cat("\\hline \n");flush.console()

as in

> cat("\\hline \n");flush.console()
\hline 

The warning when using just one kind of hints at what is going on:

> cat("\hline \n");flush.console()
hline 
Warning messages:
1: '\h' is an unrecognized escape in a character string 
2: unrecognized escape removed from "\hline \n" 

You may want to take a look the packages Hmisc and xtable, which both
have great facilities for doing latex output from all kinds of R
objects.

Regards,

markus
--
Markus Jantti
Abo Akademi University
mjantti at abo.fi
http://www.iki.fi/~mjantti