Re: [R] coda sweave

2010-04-29 Thread Randall Wrong
Thank you Bryan 2010/4/27 Brian Diggs > On 4/27/2010 1:42 PM, Randall Wrong wrote: > >> Thank you so much Ista. >> >> I have problems with pictures too. >> >> \begin{figure} >> \centering >> <>= >> xyplot( mcmc(x) ) >> @ >> \end{figure} >> >> Why doesn't this work ? Sorry for posting all these q

Re: [R] coda sweave

2010-04-27 Thread Brian Diggs
On 4/27/2010 1:42 PM, Randall Wrong wrote: Thank you so much Ista. I have problems with pictures too. \begin{figure} \centering <>= xyplot( mcmc(x) ) @ \end{figure} Why doesn't this work ? Sorry for posting all these questions :-( Best, Randall Check out FAQ 7.22. You need to use print(xy

Re: [R] coda sweave

2010-04-27 Thread Randall Wrong
Thank you so much Ista. I have problems with pictures too. \begin{figure} \centering <>= xyplot( mcmc(x) ) @ \end{figure} Why doesn't this work ? Sorry for posting all these questions :-( Best, Randall 2010/4/27 Ista Zahn > Hi Randall, > > Sounds like you need to make friends with the str()

Re: [R] coda sweave

2010-04-27 Thread Ista Zahn
Hi Randall, Sounds like you need to make friends with the str() function, and perhaps read the documentation about data types in R. For your particular problem: library(coda) m1 <- matrix(runif(100), nrow=10) m1.sum <- summary(mcmc(m1)) str(m1.sum) library(xtable) xtable(m1.sum$statistics) xtabl

Re: [R] coda sweave

2010-04-27 Thread Randall Wrong
This is the kind of output I get with summary(mcmc(x)). I would like it in LaTeX. There are two tables. Iterations = 1:10 Thinning interval = 1 Number of chains = 1 Sample size per chain = 10 1. Empirical mean and standard deviation for each variable, plus standard error of the mean: Me

Re: [R] coda sweave

2010-04-27 Thread Randall Wrong
I forgot to say that the coda package is loaded. Randall 2010/4/27 Randall Wrong > Dear R users, > > I have a matrix x of simulated values. Each column corresponds to one > variable. > > summary(mcmc(x)) works fine > > I would like however to transform the ouput into a nice LaTeX code. > > xtab

[R] coda sweave

2010-04-27 Thread Randall Wrong
Dear R users, I have a matrix x of simulated values. Each column corresponds to one variable. summary(mcmc(x)) works fine I would like however to transform the ouput into a nice LaTeX code. xtable( summary(mcmc(x)) ) does not work. Thanks Randall [[alternative HTML version deleted]]