predict_traj_input_validation: Internal function to validate inputs to trajectory prediction...

View source: R/trajectory_prediction_setup.R

predict_traj_input_validationR Documentation

Internal function to validate inputs to trajectory prediction methods.

Description

Checks that the proper combination of inputs is provided. Should be one of: new_times; new_distances; distance_lims AND timestep. If latter or new_distances, trajectory must also have inverse function. Derivative is also checked against maximum allowed.

Usage

predict_traj_input_validation(
  new_times,
  new_distances,
  distance_lims,
  timestep,
  has_inv,
  deriv,
  max_deriv
)

Arguments

new_times

A DF or vector of new time values, or NULL

new_distances

A DF or vector of new distance values, or NULL

distance_lims

A vector of min, max distance, or NULL

timestep

An integer for interpolation timestep, or NULL

has_inv

Boolean, does traj have inv fun?

deriv

vector of numeric derivs to interpolate at

max_deriv

Maximum derivative supported by traj fun

Value

Throws error only if not all OK


transittraj documentation built on Nov. 2, 2026, 1:10 a.m.