Skip to content
Prev 201735 / 398506 Next

makefile for sweave

Dear all,

I can't get texi2dvi working right. Basically I'd like to convert a .lex 
to .pdf without having to fiddle with the issue Sweave.sty not being in 
my current directory (as this was sugested in other posts on this list).

When I'm in the R-Gui I can get the help via
?texi2dvi
(So I conclude its installed.)

However, when I try to use it to concert a .tex to .pdf I get trouble ...

For example :
A)
The file "test02.r" contains :
Sweave("Sweave_test01.rnw")
library(tools)
texi2dvi("Sweave_test01.tex", pdf =T)

Now, when I run on the linux command line :
R --vanilla -q < test02.r

I get :
 > Sweave("Sweave_test01.rnw")
Writing to file Sweave_test01.tex
Processing code chunks ...
 1 : term hide (label=chunk_ini)
 2 : term verbatim eps pdf (label=Fig01)
 3 : term tex (label=packageVersionInfo)
Loading required package: xtable

You can now run LaTeX on 'Sweave_test01.tex'
 > library(tools)
 > texi2dvi("Sweave_test01.tex", pdf =T)
Error in texi2dvi("Sweave_test01.tex", pdf = T) :
  Running 'texi2dvi' on 'Sweave_test01.tex' failed.
Messages:
sh: texi2dvi: command not found
Execution halted


B)
In a previous message on this list I found the following command line(s) 
suggested, but I my case it won't work

star5_R_test_> R CMD texi2dvi --help
/usr/local/lib64/R/bin/Rcmd: line 62: exec: texi2dvi: not found

similarly, when execute (as sugested) I get the same error message

star5_R_test_> R CMD texi2dvi -p Sweave_test01.tex
/usr/local/lib64/R/bin/Rcmd: line 62: exec: texi2dvi: not found


I don't understand how can a command can be present (= installed) and 
still not being found as the error messages suggest ?

For completeness :
 > sessionInfo()
R version 2.10.0 (2009-10-26)
x86_64-unknown-linux-gnu

locale:
[1] C

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base    

other attached packages:
 [1] xtable_1.5-6         mouse4302probe_2.5.0 AnnotationDbi_1.8.1
 [4] mouse4302cdf_2.5.0   MASS_7.3-3           fdrtool_1.2.5      
 [7] limma_3.2.1          affyPLM_1.22.0       preprocessCore_1.8.0
[10] gcrma_2.18.0         affy_1.24.2          Biobase_2.6.0      

loaded via a namespace (and not attached):
[1] Biostrings_2.14.3 DBI_0.2-4         IRanges_1.4.4     RSQLite_0.7-3   
[5] affyio_1.14.0     splines_2.10.0    tools_2.10.0



Thank's in advance,
Wolfgang


Charles C. Berry a ?crit :
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Wolfgang Raffelsberger, PhD
Laboratoire de BioInformatique et G?nomique Int?gratives
IGBMC,  
1 rue Laurent Fries,  67404 Illkirch  Strasbourg,  France
Tel (+33) 388 65 3300         Fax (+33) 388 65 3276
wolfgang.raffelsberger (at) igbmc.fr