From suharto_anggono at yahoo.com  Mon Jan 28 08:54:50 2013
From: suharto_anggono at yahoo.com (Suharto Anggono Suharto Anggono)
Date: Sun, 27 Jan 2013 23:54:50 -0800 (PST)
Subject: [Rd] Minor issue in code of 'diffinv.vector' in R 2.15.2
Message-ID: <1359359690.66264.YahooMailClassic@web125102.mail.ne1.yahoo.com>

In R 2.15.2 (and not before), in the definition of function 'diffinv.vector' in package stats, there is

difference <- as.integer(differences)

I believe

differences <- as.integer(differences)

is intended, because 'difference' is not referenced anywhere. However, without conversion of 'differences' to integer, 'diffinv.vector' in R 2.15.2 works OK.


Also, to make 'differences' consistently integer,

        diffinv.vector(diffinv.vector(x, lag, differences-1,
                                      diff(xi, lag=lag, differences=1)),
                       lag, 1, xi[1L:lag])

in the end part can be changed to

        diffinv.vector(diffinv.vector(x, lag, differences-1L,
                                      diff(xi, lag=lag, differences=1L)),
                       lag, 1L, xi[1L:lag])



[Rd] Minor issue in code of 'diffinv.vector' in R 2.15.2
Suharto Anggono Suharto Anggono