---
title: Signals
layout: ../../layouts/MainLayout.astro
---

import { MiniRepl } from '../../docs/MiniRepl';
import { JsDoc } from '../../docs/JsDoc';

# Continuous Signals

Signals are patterns with continuous values, meaning they have theoretically infinite steps.
They can provide streams of numbers that can be sampled at discrete points in time.

## saw

<JsDoc client:idle name="saw" h={0} />

## sine

<JsDoc client:idle name="sine" h={0} />

## cosine

<JsDoc client:idle name="cosine" h={0} />

## tri

<JsDoc client:idle name="tri" h={0} />

## square

<JsDoc client:idle name="square" h={0} />

## Ranges from -1 to 1

There is also `saw2`, `sine2`, `cosine2`, `tri2` and `square2` which have a range from -1 to 1!

## rand

<JsDoc client:idle name="rand" h={0} />

## perlin

<JsDoc client:idle name="perlin" h={0} />

## irand

<JsDoc client:idle name="irand" h={0} />

# Random Modifiers

These methods add random behavior to your Patterns.

## chooseCycles

<JsDoc client:idle name="chooseCycles" h={0} />

## degradeBy

<JsDoc client:idle name="Pattern.degradeBy" h={0} />

## degrade

<JsDoc client:idle name="Pattern.degrade" h={0} />

## undegradeBy

<JsDoc client:idle name="Pattern.undegradeBy" h={0} />

## sometimesBy

<JsDoc client:idle name="Pattern.sometimesBy" h={0} />

## sometimes

<JsDoc client:idle name="Pattern.sometimes" h={0} />

## someCyclesBy

<JsDoc client:idle name="Pattern.someCyclesBy" h={0} />

## someCycles

<JsDoc client:idle name="Pattern.someCycles" h={0} />

## often

<JsDoc client:idle name="Pattern.often" h={0} />

## rarely

<JsDoc client:idle name="Pattern.rarely" h={0} />

## almostNever

<JsDoc client:idle name="Pattern.almostNever" h={0} />

## almostAlways

<JsDoc client:idle name="Pattern.almostAlways" h={0} />

## never

<JsDoc client:idle name="Pattern.never" h={0} />

## always

<JsDoc client:idle name="Pattern.always" h={0} />

Next up: [Conditional Modifiers](/learn/conditional-modifiers)
