s-news
[Top] [All Lists]

Re: Fan charts

To: philip.gladwin@citigroup.com, s-news@lists.biostat.wustl.edu
Subject: Re: Fan charts
From: "Greg Snow" <greg.snow@ihc.com>
Date: Fri, 14 Oct 2005 10:42:16 -0600
I don't know of anything built in, but it is not that hard to come up
with something 
fitting your description.  Try this:

tmp <- rnorm(1000,100+(1:1000)/25,10+(1:1000)/100)
tmp2 <- (1:100)*10

tmp3 <- sapply( tmp2, function(x) quantile(tmp[1:x],
c(0.01,.1,.25,.75,.9,0.99)) )

plot(c(1,100),range(tmp3), type='n', xlab='Time', ylab='something')

segments( 1:100, tmp3[1,], 1:100, tmp3[6,], col=2, lwd=3 )
segments( 1:100, tmp3[2,], 1:100, tmp3[5,], col=3, lwd=3 )
segments( 1:100, tmp3[3,], 1:100, tmp3[4,], col=4, lwd=3 )





Greg Snow, Ph.D.
Statistical Data Center, LDS Hospital
Intermountain Health Care
greg.snow@ihc.com
(801) 408-8111

>>> "Gladwin, Philip [FI]" <philip.gladwin@citigroup.com> 10/14/05
05:49AM >>>
Hello,

Can Splus produce fan charts?  My investigations so far suggest not.

These charts usually have time as the x asis and some other variable as
the
y-axis.  As each point in time there is a solid line, which is colour
coded
along its length determined by some factor e.g. a probability.

They are a great favourite at the Bank of England for illustrating the
possible
future values of interest rates.  The dark coloured regions suggesting
a high
probability of an interest rate, and a light coloured region suggesting
an
unlikely value of some interest rate.

kind regards



Phil,
--------------------------------------------------------------------
This message was distributed by s-news@lists.biostat.wustl.edu.  To
unsubscribe send e-mail to s-news-request@lists.biostat.wustl.edu with
the BODY of the message:  unsubscribe s-news


<Prev in Thread] Current Thread [Next in Thread>
  • Fan charts, Gladwin, Philip [FI]
    • Re: Fan charts, Greg Snow <=