Skip to content

Commit

Permalink
add Statistics package to file 09 - issue JuliaAcademy#89
Browse files Browse the repository at this point in the history
  • Loading branch information
mestradam committed Jul 4, 2024
1 parent a0d883e commit 65cb09b
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"outputs": [],
"cell_type": "code",
"source": [
"using Plots; gr()\nusing Images; using Interact\n\nσ(x,w,b) = 1 / (1 + exp(-w*x+b))\n\napple = load(\"data/10_100.jpg\")\nbanana = load(\"data/104_100.jpg\")\napple_green_amount = mean(Float64.(green.(apple)))\nbanana_green_amount = mean(Float64.(green.(banana)));\n\n@manipulate for w in -10:0.01:30, b in 0:0.1:30\n \n plot(x->σ(x,w,b), 0, 1, label=\"Model\", legend = :topleft, lw=3)\n scatter!([apple_green_amount], [0.0], label=\"Apple\")\n scatter!([banana_green_amount], [1.0], label=\"Banana\")\n \nend"
"using Plots; gr()\nusing Images; using Interact\nusing Statistics\n\nσ(x,w,b) = 1 / (1 + exp(-w*x+b))\n\napple = load(\"data/10_100.jpg\")\nbanana = load(\"data/104_100.jpg\")\napple_green_amount = mean(Float64.(green.(apple)))\nbanana_green_amount = mean(Float64.(green.(banana)));\n\n@manipulate for w in -10:0.01:30, b in 0:0.1:30\n \n plot(x->σ(x,w,b), 0, 1, label=\"Model\", legend = :topleft, lw=3)\n scatter!([apple_green_amount], [0.0], label=\"Apple\")\n scatter!([banana_green_amount], [1.0], label=\"Banana\")\n \nend"
],
"metadata": {},
"execution_count": null
Expand Down

0 comments on commit 65cb09b

Please sign in to comment.