idxFinalT: Time index at end of simulation

View source: R/MizerSim-class.R

idxFinalTR Documentation

Time index at end of simulation

Description

Time index at end of simulation

Usage

idxFinalT(sim)

Arguments

sim

A MizerSim object

Value

An integer giving the index for extracting the results for the final time step

Examples

idx <- idxFinalT(NS_sim)
idx
# This coincides with
length(getTimes(NS_sim))
# and corresponds to the final time
getTimes(NS_sim)[idx]
# We can use this index to extract the result at the final time
identical(N(NS_sim)[idx, , ], finalN(NS_sim))
identical(NResource(NS_sim)[idx, ], finalNResource(NS_sim))

mizer documentation built on April 26, 2023, 5:12 p.m.