Skip to contents

Renders one f.plot.rotation() frame per month of the first rotation cycle (sliding the window forward one month at a time) and assembles the frames into an animated GIF with magick. Mainly a presentation aid – the static f.plot.rotation() plot already shows the full cycle, the animation just makes it easier to follow month-by-month.

Usage

f.make.gif.rotation(
  l.res,
  input.sim.run,
  input.case,
  input.rotation.id,
  op.full.crop.list = NULL,
  op.fps = 5
)

Arguments

l.res

Named list of per-treatment results, as returned by run.socmo().

input.sim.run, input.case

Same simulation run/case identifiers passed to run.socmo(); used to locate the ./data_out/.../fig/ output folder for each treatment.

input.rotation.id

Vector of rotation IDs (positions into l.res) to animate – one GIF per ID.

op.full.crop.list

Optional full crop list (from f.get.all.crops()) forwarded to f.plot.rotation() to keep a stable color/emoji mapping across frames.

op.fps

Frames per second of the output GIF.

Value

Invisibly NULL; writes one PNG per frame to ./data_out/<input.sim.run>/<input.case>/<input.case>_<id>/fig/sources_gif/ and the assembled animation to .../fig/animation.gif. The sources_gif/ folder must already exist.