Changes

Jump to navigation Jump to search
477 bytes added ,  18:40, 5 October 2013
m
no edit summary
This page describes how to use random (to produce pseudo-random values) in ConTeXt and MetaPost. The `uniformdeviate` function in MetaPost, by default, uses a seeded value. This is useful to generate the "same" random results each time the final product is generated, but hampers creating books that differ from each other on successive generations.
A number of related commands include: * {{cmd|getrandomnumber}}- Generates a pseudo-random number each time.* {{cmd|ctxlua}}<tt>{math.randomseed(os.time())}</tt> - Sets the seed based on the computer's timestamp.
419

edits

Navigation menu