Hi, I recently compiled 1.6 on NT4 but I am having a problem with Sweave. Using the inbuilt 'Sweave-test-1.Rnw' file as an example: -------> library(tools) > testfile <- file.path(.path.package("tools"),"Sweave", "Sweave-test-1.Rnw") ## create a LaTeX file Sweave(testfile) testfile <- file.path(.path.package("tools"), + "Sweave", "Sweave-test-1.Rnw")> > ## create a LaTeX file > Sweave(testfile)Writing to file Sweave-test-1.tex Processing code chunks ... 1 : print term verbatim 2 : term hide 3 : echo print term verbatim 4 : term verbatim 5 : echo term verbatim 6 : echo term verbatim eps pdf 7 : echo term verbatim eps pdf You can now run LaTeX on Sweave-test-1.tex --------- But the opening lines of Sweave-test-1.tex are: --------- % -*- mode: noweb; noweb-default-code-mode: R-mode; -*- \documentclass[a4paper]{article} \title{A Test File} \author{Friedrich Leisch} \usepackage{a4wide} \usepackage{c:etcRrw1060/share/texmf/Sweave} \begin{document} ... ------------ The line '\usepackage{c:etcRrw1060/share/texmf/Sweave}' is wrong. In V1.5.1 it used to read \usepackage{c:/etc/R/rw1051/library/tools/Sweave/Sweave} i.e. 'c:etcRrw1060' should be 'c:/etc/R/rw1060' and I think the reference should be c:/etc/R/rw1060/library/tools/Sweave/Sweave, (not the 'share/texmf' folder) as that is where Sweave.sty is. (The only *.sty file in the folder 'share/texmf/' is Rd.sty.) Is there is something that I try to set to get Sweave insert the correct line in latex to load the Sweave.sty file? platform i386-pc-mingw32 arch i386 os mingw32 system i386, mingw32 status major 1 minor 6.0 year 2002 month 10 day 01 language R Regards, John. John Gavin <john.gavin at ubsw.com>, Quantitative Risk Models and Statistics, UBS Warburg, 100 Liverpool Street (6th floor), London EC2M 2RH, UK. Phone +44 (0) 207 567 4289 Fax +44 (0) 207 568 5352 Visit our website at http://www.ubswarburg.com This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of e-mail transmission. If verification is required please request a hard-copy version. This message is provided for informational purposes and should not be construed as a solicitation or offer to buy or sell any securities or related financial instruments. -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
Friedrich.Leisch@ci.tuwien.ac.at
2002-Oct-11 08:05 UTC
[R] problem with Sweave on 1.6 on NT4
>>>>> On Thu, 10 Oct 2002 10:44:04 +0100, >>>>> John Gavin (JG) wrote:> Hi, > I recently compiled 1.6 on NT4 but > I am having a problem with Sweave. > Using the inbuilt 'Sweave-test-1.Rnw' file as an example: > ------- >> library(tools) >> testfile <- file.path(.path.package("tools"), > "Sweave", "Sweave-test-1.Rnw") > ## create a LaTeX file > Sweave(testfile) > testfile <- file.path(.path.package("tools"), > + "Sweave", "Sweave-test-1.Rnw") >> >> ## create a LaTeX file >> Sweave(testfile) > Writing to file Sweave-test-1.tex > Processing code chunks ... > 1 : print term verbatim > 2 : term hide > 3 : echo print term verbatim > 4 : term verbatim > 5 : echo term verbatim > 6 : echo term verbatim eps pdf > 7 : echo term verbatim eps pdf > You can now run LaTeX on Sweave-test-1.tex > --------- > But the opening lines of Sweave-test-1.tex are: > --------- > % -*- mode: noweb; noweb-default-code-mode: R-mode; -*- > \documentclass[a4paper]{article} > \title{A Test File} > \author{Friedrich Leisch} > \usepackage{a4wide} > \usepackage{c:etcRrw1060/share/texmf/Sweave} > \begin{document} > ... > ------------ > The line '\usepackage{c:etcRrw1060/share/texmf/Sweave}' is wrong. > In V1.5.1 it used to read > \usepackage{c:/etc/R/rw1051/library/tools/Sweave/Sweave} > i.e. 'c:etcRrw1060' should be 'c:/etc/R/rw1060' > and I think the reference should be > c:/etc/R/rw1060/library/tools/Sweave/Sweave, > (not the 'share/texmf' folder) as that is where Sweave.sty is. > (The only *.sty file in the folder 'share/texmf/' is Rd.sty.) > Is there is something that I try to set to get Sweave > insert the correct line in latex to load the Sweave.sty file? The line is correct (I want Sweave.sty to be in $R_HOME/share/texmf), but the install procedure had a bug which I have fixed a few minutes ago. This caused Sweave.sty not to be copied to $R_HOME/share/texmf. As a quick fix for 1.6.0: please copy Sweave.sty manually to $R_HOME/share/texmf. Another thing is the c:etcRrw1060 ... does R.home() work properly on your system or do we have a problem there? Best, Fritz -- ------------------------------------------------------------------- Friedrich Leisch Institut f?r Statistik Tel: (+43 1) 58801 10715 Technische Universit?t Wien Fax: (+43 1) 58801 10798 Wiedner Hauptstra?e 8-10/1071 Friedrich.Leisch at ci.tuwien.ac.at A-1040 Wien, Austria http://www.ci.tuwien.ac.at/~leisch ------------------------------------------------------------------- -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._