# compute the instantaneous cost of raising 1000 fish on day 100
daily_cost_fun(time = 100, recruits = 1000, daily_cost = 0.05,
time_slope = 0, time_exp = 1,
rec_slope = 0.01, rec_exp = 1)
# plot a curve of instantaneous cost against time
curve(daily_cost_fun(x, 1000, 0.05, 0.01, 1.2, 0.05, 1), 0, 1000,
xlab = "Time", ylab = "$")
if (FALSE) {
# 3d plot of costs by time and recruit
emdbook::curve3d(daily_cost_fun(x, y, 0.05, 0.01, 1.2, 0.05, 1),
from = c(0, 0),
to = c(1000, 1000),
xlab = "Time", ylab = "Recruits",
zlab = "$", sys3d = "wireframe")
}
Run the code above in your browser using DataLab