From cmr.pent at gmail.com  Sun May 25 13:32:07 2008
From: cmr.pent at gmail.com (=?UTF-8?B?0JDQvdC00YDQtdC5INCf0LDRgNCw0LzQvtC90L7Qsg==?=)
Date: Sun, 25 May 2008 15:32:07 +0400
Subject: [Rd] A small modification of plot.acf (patch)
Message-ID: <5f0660120805250432p6fc51c32yef5d890b1b03d3f5@mail.gmail.com>

In one of my scripts I used plot.acf function, but I had to modify it
a little to suit my needs. Although my modifications are minor, I
believe some people might benefit from it.

The problem: currently, in cross-correlation plots main title captions
are constructed of 2 names separated by '&' symbol. Such captions
occupy too much horizontal space and usually don't fit in plot. A
better solution would be to split a caption in two lines (each name on
its separate line).

I attach a patch which adds an option to do so. Please review it and
tell me if such things are worth including into upstream version. I
have never contributed code for R project before, so please be patient
and tell me if I'm missing some fundamental things (like compatibility
with S or whatever).

The patch attached does 2 things:

1) Adds new argument main.sep. It allows to customize the titles. Now
you can even pass main.sep value containing '\n', so two parts of the
caption come on different lines. The default value preserves original
behavior.

2) Changes main title captions positioning behavior. Now they are
positioned automatically, which ensures nicely looking captions when
main.sep containing '\n' is used.

If you think the patch might be useful, please let me know and I will
submit necessary modifications to the Rd file.

Andrey Paramonov
-------------- next part --------------
A non-text attachment was scrubbed...
Name: plot.acf.patch
Type: text/x-diff
Size: 1697 bytes
Desc: not available
URL: <https://stat.ethz.ch/pipermail/r-devel/attachments/20080525/85557691/attachment.bin>


[Rd] A small modification of plot.acf (patch)
=?UTF-8?B?0JDQvdC00YDQtdC5INCf0LDRgNCw0LzQvtC90L7Qsg==?=