Re: [R] Sweave and scan()

2010-07-28 Thread Murray Jorgensen
Hi Duncan, I at first thought that your suggestion was how the .tex file should be and that this would involve tediously editing the latex source each time I updated the .Rnw. But as you probably intended I find that I can slip the Schunks and Sinputs into the .Rnw and all still works. Thank

Re: [R] Sweave and scan()

2010-07-28 Thread Duncan Murdoch
On 28/07/2010 6:33 PM, Murray Jorgensen wrote: Omigod! The archival links shows that this was the same problem that caused me to give up on Sweave about 6 years ago. I guess I never properly assimilated Brian Ripley's comments at the time. I finished up doing this: \begin{verbatim} > height

Re: [R] Sweave and scan()

2010-07-28 Thread Murray Jorgensen
Omigod! The archival links shows that this was the same problem that caused me to give up on Sweave about 6 years ago. I guess I never properly assimilated Brian Ripley's comments at the time. I finished up doing this: \begin{verbatim} > height = scan() 1: 64 62 66 65 5: 62 69 72 72 70 10: R

Re: [R] Sweave and scan()

2010-07-27 Thread Charles C. Berry
On Tue, 27 Jul 2010, Murray Jorgensen wrote: I am introducing the scan() function to my class. Consider the following file (Scanexamp.Rnw ) \documentclass[12pt]{article} \begin{document} <<>> = height = scan() 64 62 66 65 62 69 72 72 70 part = scan(what = character(0)) "Soprano" "Soprano" "

Re: [R] Sweave and scan()

2010-07-27 Thread David Winsemius
On Jul 27, 2010, at 7:01 AM, Murray Jorgensen wrote: Both suggestions generate similar errors to those of the original code. I would also be worried if the results would not puzzle my students. You are teaching them about R or about Sweave? You are setting up code that is designed to run

Re: [R] Sweave and scan()

2010-07-27 Thread Murray Jorgensen
Both suggestions generate similar errors to those of the original code. I would also be worried if the results would not puzzle my students. But thanks! Murray David Winsemius wrote: On Jul 26, 2010, at 11:54 PM, Murray Jorgensen wrote: I am introducing the scan() function to my class. Cons

Re: [R] Sweave and scan()

2010-07-27 Thread David Winsemius
On Jul 26, 2010, at 11:54 PM, Murray Jorgensen wrote: I am introducing the scan() function to my class. Consider the following file (Scanexamp.Rnw ) \documentclass[12pt]{article} \begin{document} <<>>= height = scan() 64 62 66 65 62 69 72 72 70 Have you considered adding an empty line

[R] Sweave and scan()

2010-07-26 Thread Murray Jorgensen
I am introducing the scan() function to my class. Consider the following file (Scanexamp.Rnw ) \documentclass[12pt]{article} \begin{document} <<>>= height = scan() 64 62 66 65 62 69 72 72 70 part = scan(what = character(0)) "Soprano" "Soprano" "Soprano" "Alto""Alto""Tenor" "Tenor"