File: tween_at.Rd

package info (click to toggle)
r-cran-tweenr 2.0.2-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 1,060 kB
  • sloc: cpp: 1,052; ansic: 558; sh: 13; makefile: 2
file content (31 lines) | stat: -rw-r--r-- 1,025 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/tween_at.R
\name{tween_at}
\alias{tween_at}
\title{Get a specific position between two states}
\usage{
tween_at(from, to, at, ease)
}
\arguments{
\item{from, to}{A data.frame or vector of the same type. If either is of
length/nrow 1 it will get repeated to match the length of the other}

\item{at}{A numeric between 0 and 1 recycled to match the nrow/length of
\code{from}}

\item{ease}{A character vector giving valid easing functions. Recycled to
match the ncol of \code{from}}
}
\value{
If \code{from}/\code{to} is a data.frame then a data.frame with the same
columns. If \code{from}/\code{to} is a vector then a vector.
}
\description{
This tween allows you to query a specific postion between two states rather
than generate evenly spaced states. It can work with either data.frames or
single vectors and each row/element can have its own position and easing.
}
\examples{
tween_at(mtcars[1:6, ], mtcars[6:1, ], runif(6), 'cubic-in-out')

}