extract_demand_for_fact: Extracts demand curves

View source: R/model_setup_helpers.R

extract_demand_for_factR Documentation

Extracts demand curves

Description

Extracts demand curves for each level of the factor passed to the pupil_solve call.

Usage

extract_demand_for_fact(
  aggr_dat,
  recovered_coef,
  pulse_locations,
  real_locations,
  pulses_in_time,
  expanded_time,
  expanded_by,
  factor_id = "subject",
  model = "WIER_SHARED",
  n = 10.1,
  t = 930,
  f = 1/(10^24),
  time_id = "time"
)

Arguments

aggr_dat

Aggregated data passed to solver

recovered_coef

The coefficients returned by papss::pupil_solve()

pulse_locations

The index vector pointing at pulse locations returned by papss::pupil_solve()

real_locations

The vector with the time-points at which pulses are modelled, returned by papss::pupil_solve()

pulses_in_time

Boolean vector indicating which pulse was within the time-window. Returned by papss::pupil_solve()

expanded_time

The expanded time series returned by papss::pupil_solve()

expanded_by

Expansion time in ms passed to papss::pupil_solve(expand_by=) divided by sample length in ms

factor_id

Name of factor column in aggr_dat

model

Model_template name

n

Choice for n parameter

t

Choice for t_max parameter

f

Choice for f parameter

time_id

Name of time column in aggr_dat


JoKra1/papss documentation built on June 15, 2022, 8:57 a.m.