# Gruff & Uneven Data: Interpolation or Line Connection

**URL:** <https://www.ruby-forum.com/t/gruff-uneven-data-interpolation-or-line-connection/180136>\
**Category:** Ruby\
**Created:** [December 12, 2009, 5:48pm UTC](https://www.ruby-forum.com/t/gruff-uneven-data-interpolation-or-line-connection/180136 "2009-12-12T17:48:16Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![paerez](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/p/5fc32e/32.png) [@paerez](https://www.ruby-forum.com/u/paerez)\
**Post date:** [December 12, 2009, 5:48pm UTC](https://www.ruby-forum.com/t/gruff-uneven-data-interpolation-or-line-connection/180136/1 "2009-12-12T17:48:16Z")

</div>

I often have data, for example, for interest rates with varying  
maturities, at uneven intervals - data at one, three and six months, and  
data at one through seven years.

To use Gruff to make a line graph of this data, I currently interpolate  
the data monthly, and pass an array of monthly data to Gruff.

It would be useful if Gruff could do this internally, receiving an array  
of length-two arrays, each of the latter consisting of an x and a y  
coordinate, and then interpolate to a specified division.  
Alternatively, it would be useful if Gruff could do a scatter plot and  
connect the plotted points with lines. Is this possible? If not, I  
could write a Module to do the former and submit it.
