powered by
This closure is useful for simulating q inside the sim_survey function
sim_survey
sim_logistic(k = 2, x0 = 3, plot = FALSE)
Returns a function for use in sim_survey.
The steepness of the curve
The x-value of the sigmoid's midpoint
Plot relationship
logistic_fun <- sim_logistic(k = 2, x0 = 3, plot = TRUE) logistic_fun(x = 1:10)
Run the code above in your browser using DataLab