Creating Erratic Motion Effects with Random Expressions in After Effects
Master erratic motion with random expressions
Random vs Wiggle Expression Comparison
| Feature | Random | Wiggle |
|---|---|---|
| Motion Type | Aggressive jumps | Smooth transitions |
| Value Transition | Direct jumps | Interpolates all values |
| Best Use Case | Erratic switches/dials | Natural organic motion |
| Speed Control | Requires posterizeTime | Built-in frequency |
Always position your anchor point at the center of rotation before applying random expressions to ensure proper rotation behavior
Adding Random Expression to Rotation
Access Expression Mode
Hold Option (Mac) or Alt (Windows) and click the stopwatch next to the rotation property
Clear Default Text
Remove the placeholder text that appears in the expression field
Add Basic Expression
Type 'random' in lowercase to create the basic random expression
Set Value Range
Add parentheses with min/max values like random(45, -45) to control the range
Random by itself generates very small numbers (less than 1), which creates barely visible motion. Always specify minimum and maximum values for practical results
Frame Rate Impact on Motion Speed
posterizeTime Function Applications
Speed Control
Sets a custom frame rate for expressions, allowing you to slow down rapid random motion. Essential for creating controlled erratic movement.
Expression Optimization
Reduces computational load by limiting how often the expression recalculates. Improves performance while maintaining visual effect quality.
Universal Compatibility
Works with other expressions beyond random, making it a versatile tool for controlling any expression's update frequency.
posterizeTime must be the first line in your expression. Place it before random or the expression will fail. Use semicolons at the end of each line for proper syntax.
posterizeTime(10); random(45, -45);
Random Expression Analysis
Random Expression Implementation Checklist
Ensures rotation and scaling occur around the intended center point
Removes dummy text that prevents expression from functioning
Default random values are too small for visible effects
Prevents overly rapid motion that can appear chaotic
Required syntax order or expression will fail to execute
Fine-tune between 5-15 fps for most erratic motion effects
This lesson is a preview from our After Effects Certification Course Online (includes software & exam). Enroll in a course for detailed lessons, live instructor support, and project-based training.
Key Takeaways