R: Display an easing function

display_ease {tweenr} | R Documentation

## Display an easing function

### Description

This simple helper lets you explore how the different easing functions govern the interpolation of data.

### Usage

    display_ease(ease)

### Arguments

`ease` | The name of the easing function to display (see details)

### Details

How transitions proceed between states are defined by an easing function. The easing function converts the parameterized progression from one state to the next to a new number between 0 and 1. `linear` easing is equivalent to an identity function that returns the input unchanged. In addition there are a range of additional easers available, each with three modifiers.

Easing modifiers:

-in

  The easing function is applied as-is

-out

  The easing function is applied in reverse

-in-out

  The first half of the transition it is applied as-is, while in the last half it is reversed

Easing functions

quadratic

  Models a power-of-2 function

cubic

  Models a power-of-3 function

quartic

  Models a power-of-4 function

quintic

  Models a power-of-5 function

sine

  Models a sine function

circular

  Models a pi/2 circle arc

exponential

  Models an exponential function

elastic

  Models an elastic release of energy

back

  Models a pullback and relase

bounce

  Models the bouncing of a ball

In addition to this function a good animated explanation can be found here.

### Value

This function is called for its side effects

### Examples

    # The default - identity
    display_ease('linear')

    # A more fancy easer
    display_ease('elastic-in')

[Package tweenr version 1.0.2 Index]