Torque.js is an efficient and stylish rendering method to animate your data.

This library is still under support but it will not be further developed. We don’t recommend starting new projects with it as it will eventually become deprecated. Instead, learn more about our current CARTO for deck.gl library here

Torque CartoCSS

CartoCSS is one the tools of the CARTO platform. You can learn more about the different components of CARTO platform, or directly dig into CartoCSS too details.

-torque-clear-color Color used to clear canvas on each frame.

-torque-frame-count Number of animation steps/frames used in the animation. If the data contains a fewer number of total frames, the lesser value will be used.

-torque-resolution Spatial resolution in pixels. A resolution of 1 means no spatial aggregation of the data. Any other resolution of N results in spatial aggregation into cells of NxN pixels. The value N must be power of 2.

-torque-animation-duration Animation duration in seconds.

-torque-aggregation-function A function used to calculate a value from the aggregate data for each cell. See -torque-resolution.

-torque-time-attribute The table column that contains the time information used create the animation.

-torque-data-aggregation A linear animation will discard previous values while a cumulative animation will accumulate them until it restarts.