Geom.ellipse

Geom.ellipse

Confidence ellipse for a scatter or group of points, using a parametric multivariate distribution e.g. multivariate normal. Geom.ellipse is an instance of Geom.polygon

Aesthetics

Arguments

Examples

D = dataset("datasets","faithful")
D[:g] = D[:Eruptions].>3.0

coord = Coord.cartesian(ymin=35, ymax=100)

pa = plot(D, coord,
    x=:Eruptions, y=:Waiting, group=:g,
    Geom.point, Geom.ellipse
)
pb = plot(D, coord,
    x=:Eruptions, y=:Waiting, color=:g,
    Geom.point, Geom.ellipse,
    layer(Geom.ellipse(levels=[0.99]), style(line_style=:dot)),
    style(key_position=:none), Guide.ylabel(nothing)
)
hstack(pa,pb)
Eruptions 0 1 2 3 4 5 6 50 100 Eruptions 0 1 2 3 4 5 6 50 100 Waiting