Neil, I have attached code to draw the arrowhead. -Ben |
# -*- coding: utf-8 -*- """ Spyder Editor This is a temporary script file. """
import custom_annotations
import matplotlib.pyplot as plt
plt.figure()
ax = plt.subplot(111)
length = 20.0
head_length = 7.0
#Convert the head length from mm into points (1/72")
head_length_pts = head_length * 72.0/25.4
#Calculate the head width
head_aspect_ratio = 2.5
head_width_pts = head_length_pts / head_aspect_ratio
#Define arrow style
style_str = '-)>'
arrowstyle_str = style_str + ', head_width = ' + str(head_width_pts) + \
', head_length = ' + str(head_length_pts) + ', length = ' + str(length * 72/25.4)
#Sets arrow orientation
x_1 = [0.25, 0.5]
#Sets arrowhead tip position
x_2 = [0.5, 0.5]
ax.annotate('', xytext = x_1, textcoords = 'axes fraction', \
xy = x_2, xycoords = 'axes fraction', clip_on = False, \
arrowprops = dict(arrowstyle = arrowstyle_str, mutation_scale = 1.0, \
linewidth = 1, facecolor = [0,0,0], connectionstyle = 'arc3', \
shrinkA = 0, shrinkB = 0))On May 13, 2015, at 7:44 PM, Neil Girdhar <[email protected]> wrote:
|
------------------------------------------------------------------------------ One dashboard for servers and applications across Physical-Virtual-Cloud Widest out-of-the-box monitoring support with 50+ applications Performance metrics, stats and reports that give you Actionable Insights Deep dive visibility with transaction tracing using APM Insight. http://ad.doubleclick.net/ddm/clk/290420510;117567292;y
_______________________________________________ Matplotlib-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/matplotlib-devel
