Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6561691
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T13:37:08+00:00 2026-05-25T13:37:08+00:00

I’m following Gregor Gorjanc’s tutorial on LyX & Sweave . Using Ubuntu 10.04 and

  • 0

I’m following Gregor Gorjanc’s tutorial on LyX & Sweave. Using Ubuntu 10.04 and LyX version 1.6.5 with all of texlive-full installed.

R scraps which result in numerical output produce a valid PDF.

But, when I try to compile simple figures like

<<chunk, fig=T>>=       [ctrl+enter]
hist(rnorm(100))        [ctrl+enter]
@

I get cryptic errors. Either that chunk.temp.Rnw wasn’t found, or that LaTeX encountered an error and I should hit <enter> to ignore.

If I change fig to figure and T to TRUE, then the LyX document compiles but displays no graphics. With pgfsweave I get this error, or sometimes this one.

Am I working with the wrong versions of these programs? Is there a way to elicit better error messages? Can I somehow dive into the LaTeX prompt and hit <enter> myself?

update: I was using the wrong version of LaTeX; Ubuntu’s default is too old. Also I needed to update to LyX 2.0.1 and a newer version of pgf and pgfSweave (the programs are distinct).

The new (nondescript) error message is: An error occurred while running: Rscript '/home/mars/.lyx/scripts/lyx-sweave-exec.R' 'UTF-8' 'pgfSweave' "/home/mars/" "/tmp/lyx_tmpdir.T1663/lyx_tmpbuf2/" "test.sweave.lyx.Rnw" > "test.sweave.Rnw".log 2>&1

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T13:37:09+00:00Added an answer on May 25, 2026 at 1:37 pm

    According to https://tex.stackexchange.com/questions/27993/can-i-download-ctan-packages-from-the-command-line-ubuntu/27994#27994 there is a perennial problem with TeX in Ubuntu: their packages are way behind. Since many innovations with Sweave have happened in 2010-2011, it seems one must download and install an .iso from http://ftp.ctex.org/mirrors/CTAN/systems/texlive/Images/ rather than use Synaptic. So much for package management!

    I’ll accept my own answer only if this actually works.

    update: Make sure you disregard anything you read about Noweb.sty because in LyX 2.0.1 there is a “Sweave Module” meaning you should just use regular document classes (article, book, report) — the scraps are replaced by chunks and essentially Sweave is handled natively. Also disregard Brett Collier’s lucid explanation of how to install LyX because it’s now outdated, despite Gregor Gorjanc’s highly-googleable blog post saying it works. That is also outdated, or maybe it only works in Ubuntu 9 and not Ubuntu 10.04.

    So the steps to successfully getting Sweave to work in LyX for Ubuntu 10.04 as of August 2011 are:

    1. Get the newest texlive from tug.org — not the one from Synaptic. How to do that: https://tex.stackexchange.com/questions/27993/can-i-download-ctan-packages-from-the-command-line-ubuntu/27994
    2. Get pgf and kTikz as described here: http://justbloodywork.blogspot.com/2011/07/installing-latex-and-pgf.html
    3. Follow Yihue’s instructions here: http://yihui.name/en/2010/10/how-to-start-using-pgfsweave-in-lyx-in-one-minute/#comment-10929. Build lyx-devel from source, apply Yihue’s patch, and configure some LyX preferences.
    4. Tools > Reconfigure LyX.
    5. Pray.
    6. Start LyX and load Yihue’s test file from (3). Hit Ctrl + R, not Ctrl + D to view.
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
link Im having trouble converting the html entites into html characters, (&# 8217;) i
I'm using v2.0 of ClassTextile.php, with the following call: $testimonial_text = $textile->TextileRestricted($_POST['testimonial']); ... and
I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this
That's pretty much it. I'm using Nokogiri to scrape a web page what has
We're building an app, our first using Rails 3, and we're having to build
We are using XSLT to translate a RIXML file to XML. Our RIXML contains
I have a text area in my form which accepts all possible characters from
I am reading a book about Javascript and jQuery and using one of the
I have thousands of HTML files to process using Groovy/Java and I need to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.