display a path?

i apologize in advance for what is undoubtedly a silly question, but, having
looked through the coding examples and the forum i am still a little
confused...

am i correct in understanding that the only way to draw / display a path on
an axes is by converting it to a PathPatch and adding that to the axes?

ideally i would like to display a PathPatch as well as parts of the path
that surround it. to do this i would like to show the PathPatch with no edge
and then also show part of the path (with no fill).

thanks in advance,

lb

···


View this message in context: http://www.nabble.com/display-a-path--tp23805921p23805921.html
Sent from the matplotlib - users mailing list archive at Nabble.com.

If your path has bezier curve segments, then, yes, PathPatch is the most direct method (see the dolphin.py example). However, if you just need a series of line segments, then Polygon is probably much simpler for filling areas.

Mike

lucab wrote:

···

i apologize in advance for what is undoubtedly a silly question, but, having
looked through the coding examples and the forum i am still a little
confused...

am i correct in understanding that the only way to draw / display a path on
an axes is by converting it to a PathPatch and adding that to the axes?

ideally i would like to display a PathPatch as well as parts of the path
that surround it. to do this i would like to show the PathPatch with no edge
and then also show part of the path (with no fill).

thanks in advance,

lb
  
--
Michael Droettboom
Science Software Branch
Operations and Engineering Division
Space Telescope Science Institute
Operated by AURA for NASA

Mike,

thanks so much for the response. my intent is to build compound paths that
(ideally) include bezier curve approximations to circle segments and
straight-line elements. the final output will most likely be an SVG file so
it would be nice to keep the beziers. but since i'm new to matplotlib, scipy
and python in general this may be trying to bite off more than i can chew.
:wink:

lb

Michael Droettboom-3 wrote:

···

If your path has bezier curve segments, then, yes, PathPatch is the most
direct method (see the dolphin.py example). However, if you just need a
series of line segments, then Polygon is probably much simpler for
filling areas.

Mike

--
View this message in context: http://www.nabble.com/display-a-path--tp23805921p23820801.html
Sent from the matplotlib - users mailing list archive at Nabble.com.