Skip to content

Instantly share code, notes, and snippets.

@alstat

alstat/bsl-6.jl Secret

Last active March 1, 2020 09:39
yhat = west[1] .+ west[2].*collect(-1:0.1:1)
l = @layout[p p];
p1 = plot(
x, y,
xlab = "x",
ylab = "y",
title = " \nSampled Data with n=20",
title_location = :left,
markershape = :circle,
markersize = 5,
markeralpha = 0.5,
markerstrokewidth = 0,
linealpha = 0,
legend = false
)
p2 = deepcopy(p1)
plot!(p2, -1:0.1:1, yhat, title = " \nFitted Line (Frequentist)", linewidth = 2)
plot(p1, p2, layout = l, size = (700, 400), margin = 5mm, link = :y)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment