Digit

The Digit field type generates a random digit.

Schema

fields:
  - name: Digit One
    type: Digit
    null_probability: 0.5
  - name: Digit Two
    type: Digit
    constraints:
      - type: IfNull
        name: Digit One

Output

Digit OneDigit Two
1
3
8
6
4

Arguments

NameTypeDescriptionDefault

Field arguments

NameTypeDescriptionDefault Value
null_probabilityfloatThe probability that the field will be null.0.0
constraintslistA list of constraints to apply to the field.[]

Supported constraints

NameDescription
IfNullThe value must only be non-null if another field is null.