# Generate and plot 100 linear models for a parameter across a latitudinal gradient.
# Param values must be between 1 and 10 at the equator and between 0 and 9 at 60 degrees.
mods = model_generator(domain=c(0,60), par_low=seq(1, 10), par_high=seq(0,9))
curve(expr=(y=mods[1,1]*x + mods[1,2]), ylim=c(0,10), xlim=c(0,60), ylab="Parmam Value",
xlab="Abs. Latitude")
for(i in 2:nrow(mods)) curve(expr=(y=mods[i,1]*x + mods[i,2]), add=TRUE)
Run the code above in your browser using DataLab