Ask Your Question

Notebook errors when compiling Sage from source

asked 2012-02-02 19:23:05 +0200

Rubin gravatar image

Hi, everyone. I've been using the Sage binary on Kubuntu 11.10 and decided to try compiling Sage for better R support. It compiled, but the notebook is not working properly -- it gives me no output. I type in commands, click on "evaluate," and nothing happens, regardless of what the command was. No confirmations, no graphs, no error messages, no nothing. The binary works, but not what I compiled from source.

My system is using the 3.0.0-12-generic kernel, and I have all the packages (build-essential, gfortran, M4, bison) mentioned in the installation guide. I made sure to explicitly set the path to gfortran (export SAGE_FORTRAN=/usr/bin/gfortran). I couldn't find, however, so I couldn't set SAGE_FORTRAN_LIB.

Any suggestions? I appreciate the help given on my last question a while back, and am hoping the Sage community can field this one again.

edit retag flag offensive close merge delete


It sounds like you might want to post a link to the build log. Did the build actually finish? It sounds like you are able to try to launch the notebook - what command are you using for this.

kcrisman gravatar imagekcrisman ( 2012-02-02 20:58:17 +0200 )edit

Good question. It looks like how I was launching the notebook was causing things to act funny. I had redone my server from scratch and accidentally was using the command from Jason Grout's sage server wiki. But since I never set up those sage user accounts that he did, I didn't need all the server_pool and ulimit options. Removing those and invoking sage with just "sage -c "notebook(interface='localhost', directory='./sage_notebook.sagenb',port=8000, accounts=False, timeout=3600, open_viewer=False)" " is getting my outputs back. Thanks!

Rubin gravatar imageRubin ( 2012-02-04 09:02:12 +0200 )edit

1 Answer

Sort by ยป oldest newest most voted

answered 2012-02-02 21:01:36 +0200

kcrisman gravatar image

When it comes to just better R support, you could just follow the directions in Jason Grout's comment at this question. Basically, install a couple other packages and then force rebuild Sage.

Incidentally, we just upgraded R in Sage to 2.14.0.

edit flag offensive delete link more


Now that I can see my output, I see that the version of R I compiled is not giving the usual "Error in png() : X11 is not available" error when I try to make a graph, which is good. "r.eval('capabilities("png")')" and "r.eval('capabilities("X11")')" both come up true. But I'm not seeing any graphs when I try to use R for plotting -- I get no output or errors. 2D and 3D plots with Sage display properly, though.

Rubin gravatar imageRubin ( 2012-02-04 09:16:16 +0200 )edit

Looks like when I select Sage as the interpreter in the notebook I get an output, for example "r.plot(r.rnorm(100))" gives me the right graph (along wit the response "null device 1"). But selecting R as the interpreter in the notebook and then evaluating "plot(rnorm(100))" gives no output.

Rubin gravatar imageRubin ( 2012-02-04 09:36:12 +0200 )edit

That's to be expected; "raw" R requires that you open and close a graphics device to plot, so you would have to do that too. See my comment toward the bottom of

kcrisman gravatar imagekcrisman ( 2012-02-04 20:42:41 +0200 )edit

That did the trick! Thank you very much!

Rubin gravatar imageRubin ( 2012-02-04 23:07:29 +0200 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools


Asked: 2012-02-02 19:23:05 +0200

Seen: 427 times

Last updated: Feb 02 '12