h-Klok / StatsWithJuliaBook

https://statisticswithjulia.org/
MIT License
1.08k stars 279 forks source link

[support] "UndefVarError: @formula not defined" error when running example listing 8.5 #17

Closed woshidama323 closed 5 years ago

woshidama323 commented 5 years ago
import DataFrames, GLM, PyPlot , Statistics, CSV
data = CSV.read("../data/weightHeight.csv")
lm1 = lm(@formula(Height ~ Weight), data)

when running this piece of code , I found an error with "UndefVarError: @formula not defined"

julia version : 1.1.1

woshidama323 commented 5 years ago

sorry my mistake, it's "using" not "import"