On 11/18/2011 1:22 AM, ren...@vannieuwkoop.ch wrote:
\documentclass[11pt,a4paper]{article}
\usepackage{Sweave}
\begin{document}
<<>>=
x  =  runif(100,  1,  10)
y  =  2  +  3  *  x  + rnorm(100)
@

<<echo=FALSE,results=tex>>=
library(xtable)
print(xtable(summary(lm(y~x)),
align="rcccc",
caption="Summary  statistics  for  the  regression  model",
caption.placement="top", label="tab:summary",
digits=2))

@

\end{document}

caption.placement is an argument to print.xtable, not xtable.

print(xtable(summary(lm(y~x)),
             align="rcccc",
             caption="Summary  statistics  for  the  regression  model",
             label="tab:summary",
             digits=2),
      caption.placement="top")


--
Brian S. Diggs, PhD
Senior Research Associate, Department of Surgery
Oregon Health & Science University

______________________________________________
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