title: How to plot contour maps and display average of the mark(associated with x,y) for each contour level
body: <p>I have a contour map in spatstat generated from the intensity function of a point pattern X (like "location of the trees"). Each x,y coordinates in this point pattern is marked with a corresponding third vector (like "diameter of the tree").
  -->cf image (of course the vertical lines representing the tree can be omitted)</p>
  
  <p>I would like to display the average of the mark (diameter) in each level of the contour with different colors. Suggestions?
  Thanks!</p>