import { SquiggleChart } from "../components/SquiggleChart"; import { Canvas, Meta, Story, Props } from "@storybook/addon-docs"; export const Template = SquiggleChart; /* We have to hardcode a width here, because otherwise some interaction with Storybook creates an infinite loop with the internal width */ const width = 500; # Squiggle Chart Squiggle chart evaluates squiggle expressions, and then returns a graph representing the result of a squiggle expression. A squiggle expression can have three different types of returns. A distribution, a constant, and a function. A distribution means that the result forms a probability distribution. This could be continuous, discrete or mixed. ## Distributions ### Continuous Distributions {Template.bind({})} ### Discrete Distributions {Template.bind({})} ## Mixed distributions {Template.bind({})} ## Constants A constant is a simple number as a result. This has special formatting rules to allow large and small numbers being printed cleanly. {Template.bind({})} ## Functions Full functions can be returned. These plot out the results of distributions between a set of x-coordinates. The default is show 10 points between 0 and 10. {Template.bind({})} ## Errors {Template.bind({})}