def coarsen_line(line, level=<NUM_LIT:2>, exponential=False, draw=True):
<EOL>xdata = line.get_xdata()<EOL>ydata = line.get_ydata()<EOL>xdata,ydata = _fun.coarsen_data(xdata, ydata, level=level, exponential=exponential)<EOL>if len(ydata) == <NUM_LIT:0>: print("<STR_LIT>"+str(line)+"<STR_LIT:!>")<EOL>else: line.set_data(xdata, ydata)<EOL>if draw: _pylab.draw()<EOL>
Coarsens the specified line (see spinmob.coarsen_data() for more information).

Parameters
----------
line
    Matplotlib line instance.
level=2
    How strongly to coarsen.
exponential=False
    If True, use the exponential method (great for log-x plots).
draw=True
    Redraw when complete.