Suppress output when using Weave

I noticed that I can’t suppress output using a semicolon when creating a document using Weave. For example:

#' Test Weave's handling of output suppression via ;
c = rand();
#' should show no output.

Here’s what the HTML looks like:

How can I suppress output?

You have to set the chunk option results="hidden". This can be done with a line starting with #+ above your chunk.

#' Test Weave's handling of output suppression via
#+ results="hidden"
c = rand()
c += 1
#' should show no output.
c
2 Likes