4
$\begingroup$

I cannot find a list of standard plot markers (square, trinagle, dot, circle, disk, cross, plus, ...) and how to use them.

Fore example I can access a self made cross, by:

cross = Graphics[{Blue, Line[{{{-1, -1}, {1, 1}}, {{-1, 1}, {1, -1}}}]}];

ListPlot[{{1, 1}, {2, 2}}, PlotMarkers -> {cross, 0.1}, PlotRange -> {{0, 2.5}, {0, 2.5}}, 
 AspectRatio -> Automatic]

enter image description here

Is this symbol and the others in the list predefined, and how can I use them in a plot?

UPDATE:

Following Carl Wolls proposal I tried:

p = Style[Graphics`PlotMarkers[][[6, 1]], FontFamily -> "Times"];

circle = Graphics[Circle[{0, 0}, 1]];

range = Range[0.9, 1.15, 0.1];

ListPlot[{{{1, 1}, {2, 2}}, {{1, 1}, {2, 2}}, {{1, 1}, {2, 2}}}, 
 PlotMarkers -> {{p, 300}, {cross, 0.05}, {circle, 0.3}}, GridLines -> {range, range}, 
 PlotRange -> {{0.8, 1.15}, {0.8, 1.15}}, AspectRatio -> Automatic]

enter image description here

As you see the symbol p is still not centered around the data point {1,1}, whereas circle and cross are correct.

$\endgroup$
10
  • 4
    $\begingroup$ You might be interested in this. $\endgroup$ Commented Aug 23, 2017 at 15:50
  • 1
    $\begingroup$ @J. M. Thank you, this link is very helpfull ... so there is no symbol predefined in 11.1.1? $\endgroup$
    – lio
    Commented Aug 23, 2017 at 16:17
  • 2
    $\begingroup$ From here can try Graphics`PlotMarkers[] $\endgroup$ Commented Aug 23, 2017 at 16:31
  • 1
    $\begingroup$ @Bob Hanlon: I tested a few special characters and none of them is really centered. For scientific presentation they should be centered around 0 as the cross in my example. $\endgroup$
    – lio
    Commented Aug 23, 2017 at 17:07
  • 4
    $\begingroup$ I wouldn't use the standard markers exactly because they are not properly centered (that's because they use font glyphs instead of graphics primitives). I usually use what's in JM's link. $\endgroup$
    – Szabolcs
    Commented Aug 24, 2017 at 9:02

0

Browse other questions tagged or ask your own question.