First time here? Check out the FAQ!

Ask Your Question
1

hide the entries when export html

asked 3 years ago

ErWinz gravatar image

updated 1 year ago

FrédéricC gravatar image

hi i export to html to put on my servor so that students can see the graphs how can i hide the entries, keeping visible on the html only the outputs ? Vinz

Preview: (hide)

2 Answers

Sort by » oldest newest most voted
1

answered 3 years ago

rburing gravatar image

When you download a Jupyter notebook as HTML, nbconvert is used to do the conversion. The nbconvert program is highly flexible when you use it directly from the command line or as a library (the "Download as" functionality in Jupyter notebooks just uses this program with some specific sets of arguments). Using nbconvert as a library shows how to extract figures. Removing cells, inputs, or outputs is also possible. So, with some programming effort it should be possible to automate what you want to do with a single call to nbconvert.

Preview: (hide)
link
0

answered 3 years ago

slelievre gravatar image

One can

  • save 2D graphics to png
  • save 3D graphics to html

and they are then easy to include in web pages.

Examples:

sage: parabola = plot(lambda x: x^2, (-1, 1))
sage: parabola.save('parabola.png')

sage: xyz = (lambda u, v: u*cos(v), lambda u, v: u*sin(v), lambda u, v: u^2)
sage: paraboloid = parametric_plot3d(xyz, (0, 1), (0, 2*RDF.pi()))
sage: paraboloid.save('paraboloid.html')
Preview: (hide)
link

Your Answer

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

Add Answer

Question Tools

1 follower

Stats

Asked: 3 years ago

Seen: 251 times

Last updated: Nov 17 '21