Skip to contents

moveVis provides tools to visualize movement data (e.g. from GPS tracking) and temporal changes of environmental data (e.g. from remote sensing) by creating video animations. The moveVis package is closely connected to the move2 package and builds up on ggplot2 grammar of graphics.

Details

The package includes the following functions, sorted by the order they would be applied to create an animation from movement data:

Preparing movement tracks

  • align_move aligns single and multi-individual movement data to a uniform time scale with a uniform temporal resolution needed for creating an animation from it. Use this function to prepare your movement data for animation depending on the temporal resolution that suits your data.

Creating frames

  • get_maptypes returns available map services and types that can be used with frames_spatial. This function is reexported from the <a href="https://jakob.schwalb-willmann.de/basemaps/">basemaps</a> package.

  • frames_spatial creates moveVis frames from movement and map/raster data, displaying movement-environment interactions spatio-temporally. Frames are returned as an object of class moveVis and can be subsetted, viewed (see render_frame), modified (see add_gg and associated functions) and animated (see animate_frames).

  • frames_graph creates moveVis frames displaying movement-environment interaction graphs. Frames can be viewed or modified individually and animated using animate_frames.

Adapting frames

Animating frames (as GIF or video)

  • suggest_formats returns a selection of suggested file formats that can be used with out_file of animate_frames on your system.

  • animate_frames creates an animation from moveVis frames, e.g as .gif or .mov video file.

Viewing movement tracks

  • render_frame renders an individual frame. It yields the same result as if an individual frame is extracted using [[]].

  • view_spatial displays movement tracks on an interactive mapview or leaflet map.

Methods

  • [.moveVis extracts individual frames or a sequence of frames from a moveVis frames object.

  • [[.moveVis renders an individual frame, like render_frame does.

  • c combines multiple moveVis frames.

  • tail and head return n last or first frames of a moveVis frames object.

  • length returns the length of moveVis frames, i.e. number of frames.

  • print shows basic information about a moveVis frames object, i.e. number of frames, extent and more.

  • rev reverses the order of a moveVis frames object.

Processing settings

  • use_multicore enables multi-core usage for computational expensive processing steps.

  • use_disk enables the usage of disk space for creating frames, which can prevent memory overload when creating frames for very large animations.

Example data

  • move_data, a move2 object representing coordinates and acquisition times of three simulated movement tracks, covering a location nearby Lake of Constance, Germany.

  • whitestork_data, a data.frame and a move2 object, both representing coordinates and acquisition times of 15 White Storks, migrating from Lake of Constance, SW Germany, to Africa.

  • example_data, two SpatRasterDatasets, representing simulated NDVI images and an NDVI-derived classification covering the Lake of Constance area, as well as invented dates and times that simulate acquisition times.

The majority of these functions can be used with the forward pipe operator %>%, which is re-exported by moveVis.

Author

Jakob Schwalb-Willmann. Maintainer: Jakob Schwalb-Willmann, moveVis@schwalb-willmann.de