Platform
Resources
Pricing
Sign in
Contact us
Charles Redmond
Workspace
Fork
Published
Fall21CalcApp
By
Charles Redmond
Edited
Nov 23, 2021
1 star
Fall21CalcApp
Plotting Template
Markdown
TeX
Arrays and Objects
Plotting Method 1
Plotting Method 2
Plotting Method 3
Plotting Example
Horizontal Lines
Cars/Horizontal Line
Slope
Lines
Best Fitting Line
Parabola
Sine
Exponential Function
Logarithmic Function
Growth Rates
Sigmoid Function
Derivative of Parabola
Derivative of Sine
Derivative of Exponential Function
Derivative Using Chain Rule
Blocks of Code
For Loops
Gradient Descent
Gradient Descent
The MSE
MSE With Just Slope
Gradient Descent Program
Classes
Regression Module
Penguins
Penguins Application
Baseball Application
Planes
Paraboloid
Sine Wave
Another Sine Wave
The Gradient
Gradient Descent with Paraboloid
Gradient Descent with a Sine Wave
Gradient Descent with another Sine Wave
Regression Revisited
Minimizing MSE
Regression Class
Penguins
Regression Class (with second predictor)
Derivative Practice
Exam Practice
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
msePartialw
=
(
w
,
b
)
=>
{
const
summand
=
X
.
map
(
(
x
,
i
)
=>
(
Y
[
i
]
-
w
*
X
[
i
]
-
b
)
*
X
[
i
]
)
return
-
2
*
d3
.
sum
(
summand
)
/
4
}
Insert cell
msePartialb
=
(
w
,
b
)
=>
{
const
summand
=
X
.
map
(
(
x
,
i
)
=>
(
Y
[
i
]
-
w
*
X
[
i
]
-
b
)
)
return
-
2
*
d3
.
sum
(
summand
)
/
4
}
Insert cell
Insert cell
coordinates
=
{
const
coordinates
=
[
]
let
w
=
w0
let
b
=
b0
for
(
let
i
=
0
;
i
<=
1000
;
i
=
i
+
1
)
{
coordinates
.
push
(
[
w
,
b
]
)
w
=
w
-
.01
*
msePartialw
(
w
,
b
)
b
=
b
-
.01
*
msePartialb
(
w
,
b
)
}
return
coordinates
}
Insert cell
w
=
coordinates
[
step
]
[
0
]
Insert cell
b
=
coordinates
[
step
]
[
1
]
Insert cell
Purpose-built for displays of data
Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Try it for free
Learn more
Fork
View
Export
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
w0
Edit
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
b0
Edit
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
step
Edit
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
X
Edit
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Y
Edit
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
mse
Edit
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
msePartialw
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
msePartialb
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
grid
Edit
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
coordinates
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
w
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
b
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML