Back to Recipes Homepage
recipe picture
Recipe: LuaRandom
Created by LociOiling 2 1
Your rating: None Average: 5 (2 votes)


Name: LuaRandom
ID: 101668
Created on: Tue, 12/08/2015 - 22:44
Updated on: Wed, 12/09/2015 - 06:48

Not a foldit recipe. This standalone Lua script generates a 512x512 random bitmap in PNG format.

Best For


LociOiling's picture
User offline. Last seen 1 hour 13 min ago. Offline
Joined: 12/27/2012
generates a random bitmap

This is a standalone command-line Lua script, not a foldit recipe.

This script generates a random 512x512 black and white bitmap.

Each bit is randomly selected.

The goal is to visually assess the quality of the random number generator. A second script, LuaRandom2, can be used to generate a bit from the output of the random number generator found in foldit, via the randomeer recipe. The two output files can then be compared.

See for a detailed example

This script is based on the PHP script found in

This script is shared as a foldit recipe, but requires a standalone Lua environment.

This is a command-line LUA program. The command line syntax is:

lua LuaRandom.lua *outfile*.png

where *outfile* is the output file name.

Want to try?
Add to Cookbook!
To download recipes to your cookbook, you need to have the game client running.





Developed by: UW Center for Game Science, UW Institute for Protein Design, Northeastern University, Vanderbilt University Meiler Lab, UC Davis
Supported by: DARPA, NSF, NIH, HHMI, Amazon, Microsoft, Adobe, Boehringer Ingelheim, RosettaCommons