PLAYGROUND (experimental)

graph_plot

Draw a scatter plot (nuage de points) from two lists of x and y values. The plot is automatically scaled to fit the specified dimensions.
graph_plot(
    x, 
    y, 
    [width=320], 
    [height=200], 
    [padding=20], 
    [graduations], 
    [xmin], 
    [xmax], 
    [ymin], 
    [ymax], 
    [radius=3], 
    [stroke=#000000], 
    [fill=#FFFFFF], 
    [weight=1.00]
)

Draw a scatter plot (nuage de points) from two lists of x and y values. The plot is automatically scaled to fit the specified dimensions.

Syntaxe

var x = [1, 2, 3, 4, 5];
var y = [10, 20, 15, 25, 30];
graph_plot(x, y, width=400, height=300, padding=40, graduations="#000", radius=5, fill="#FF5722");

Arguments

NameTypeRequiredDefaultDescription
xyes-List of x values
yyes-List of y values
width-320width of graph area
height-200height of graph area
padding-20Internal padding
graduations--Color of axes and ticks (e.g. '#000'). If 'none', no graduations.
xmin--Override minimum X value
xmax--Override maximum X value
ymin--Override minimum Y value
ymax--Override maximum Y value
radius-3radius of circles
stroke-#000000Stroke color
fill-#FFFFFFFill color
weight-1.00Stroke weight (thickness)