[R-sig-finance] (i) bug report in listFinCenter and (ii) question
Parlamis Franklin
fparlamis at gmail.com
Wed Oct 5 02:46:20 CEST 2005
Hello all.
I am using the Mac OS X version of R (Aqua GUI 1.12, R Framework
2.1.1).
(i) The function 'listFinCenter' in the fCalendar package does
not work. Having checked the code of that function it appears the
problem is in the passing of the '*' regular expression pattern to
the R grep function. R complains that this is not a valid regular
expression. I am not sure whether this bug is the result of more
liberal regular expression matching on the Windows platform (on which
fCalendar has been exclusively tested) than on UNIX, or whether it
results from the fact that R, as of version 2.1.0, has switched its
standard for regular expression matching to glibc 2.3.3 from grep 2.4.2.
In any event, I have found that replacing the pattern '*' with
the pattern '.*' will do the trick (although I must admit the entire
grep call seems a bit superfluous to me--perhaps the function was
originally intended to do more than it currently does).
(ii) As we all know by now, fCalendar needs the TZ environment
variable to be set to 'GMT'. However, as installed on my Mac, a
Sys.getenv() call returned no environment variable named TZ. My
solution was to use Sys.putenv() in my .Rprofile file to initialize
and set the TZ variable to 'GMT'. This stopped the program from
complaining, but I am a bit concerned that the solution will not be a
complete one. My system clock is still set to my local time zone and
daylight savings rules, so that other programs in other environments
on my system know the time to be different than R. Does anyone
foresee a problem with this workaround? Is there a better way?
Thanks in advance.
Franklin Parlamis
More information about the R-sig-finance
mailing list