god: god

Description Usage Arguments Details Value Examples

View source: R/god.R

Description

The spark of all life in the Game of Evolution aka organism initialization function

Usage

1
god(I, J, density)

Arguments

I

number of rows in organism

J

number of columns in organism

density

Range = [0,1]. Probabilty a given cell is set to 1

Details

Create a binary matrix of size I x J and return it as an 'organism' object

Value

An organism-class object

Examples

1
2
# Create a 9x9 matrix with 50% "on" density
god(I = 9, J = 9, density = 0.5)

fransilvion/REvolution documentation built on Nov. 4, 2019, 12:57 p.m.