# Stitching (Random Walk Algorithm) > Stitching explores the painting of shapes from left to right across a blank canvas **Published by:** [henrypye](https://paragraph.com/@henrypye/) **Published on:** 2023-12-04 **Categories:** artwork **URL:** https://paragraph.com/@henrypye/stitching-random-walk ## Content This piece was created on a rainy evening in Venice Beach. This piece uses a rate to draw items across the canvas. When the rate is higher, the piece appears more disparate as the draw speed is much faster.This is a result of using a custom random walk algorithm. let yy = sin(noise(xx+xo*a)*29)*0.5+0.5; let d0 = noise(xx+xo*b+height)*2-1; let d1 = noise(xo+xx*b-height)*2-1; crss(xx+4, height * yy+2, d0*40, d1*40, "#000"); crss(xx+4, height * yy+2, d0*40, d1*40, chosenPal[colori]); crss(xx+4, height * yy+4, d0*80, d1*80, "#fff"); crss(xx, height * yy, d0*80, d1*80, chosenPal[colori]); xx += rate; if (xx >= width+80) { xx = -80; xo = 777; iterations++; rate += 0.1; }The variation in these outputs can be seen below. The more disparate the sketch, the higher the initial draw rate. ## Publication Information - [henrypye](https://paragraph.com/@henrypye/): Publication homepage - [All Posts](https://paragraph.com/@henrypye/): More posts from this publication - [RSS Feed](https://api.paragraph.com/blogs/rss/@henrypye): Subscribe to updates ## Optional - [Collect as NFT](https://paragraph.com/@henrypye/stitching-random-walk): Support the author by collecting this post - [View Collectors](https://paragraph.com/@henrypye/stitching-random-walk/collectors): See who has collected this post