Draw any type of geom
import ggplotd.geom : geomType; geomType(Aes!(double[], "x", double[], "y", string[], "type") ( [0.0,1,2], [5.0,6,7], ["line", "point", "line"] ));
import std.range : walkLength; assertEqual( geomType(Aes!(double[], "x", double[], "y", string[], "type") ( [0.0,1,2], [5.0,6,7], ["line", "point", "line"] )).walkLength, 2 );
Draw any type of geom
The type field is required, which should be a string. Any of the geom* functions in ggplotd.geom can be passed using a lower case string minus the geom prefix, i.e. hist2d calls geomHist2D etc.