Hello,

Why not use package xtable? I've just tried the following.

#install.packages('xtable')
library(xtable)

x <- 1:20
y <- 0.5*x + rnorm(20)

fit <- aov(y ~ x)
latex.tbl <- xtable(fit)
align(latex.tbl) <- "|lrrrrr|"
print(latex.tbl)

The output was

% latex table generated in R 2.15.1 by xtable 1.7-0 package
% Tue Oct 09 08:12:33 2012
\begin{table}[ht]
\begin{center}
\begin{tabular}{|lrrrrr|}
  \hline
 & Df & Sum Sq & Mean Sq & F value & Pr($>$F) \\
  \hline
x & 1 & 191.80 & 191.80 & 208.27 & 0.0000 \\
  Residuals & 18 & 16.58 & 0.92 &  &  \\
   \hline
\end{tabular}
\end{center}
\end{table}


Hope this helps,

Rui Barradas


Em 09-10-2012 04:47, killerkarthick escreveu:
Thanks arun,
                    But what is the alternative solution in windows. Please
reply me.................................



--
View this message in context: 
http://r.789695.n4.nabble.com/How-to-create-a-table-with-borders-tp4645470p4645527.html
Sent from the R help mailing list archive at Nabble.com.

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to