Notebooks 2.0 is here.

Public
Edited
Oct 18, 2023
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
coloured_formulas_2 = md`We can see that the ${tex`\colorbox{${scenario_match_colour}}{$\text{yellow area} = \lambda m$}`} and the
${tex`\colorbox{${scenario_non_match_colour}}{$\text{blue area} = (1-\lambda) u$}`}.

So:

${tex`\text{match probability} = \frac{\colorbox{${scenario_match_colour}}{{$\lambda m$}}}{\colorbox{${scenario_match_colour}}{$\lambda m$} + \colorbox{${scenario_non_match_colour}}{$(1-\lambda)u$} } `}

Which is our original formula.`
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
scenario_match_colour = d3.color("rgb(255, 255, 34)").hex()
Insert cell
scenario_non_match_colour = "#35cbff"
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.
Learn more