[R-SIG-Finance] Fwd: blotter, quantstrat: initDate without effect?

Robert Iquiapaza rbali at ufmg.br
Fri Oct 28 13:20:07 CEST 2011


Andreas
I am not sure if is availability data problem, the from="2004-11-02" gives 
the error

library(quantmod)
getSymbols(symbol,from="2004-11-30",to="2005-10-26")  # works

getSymbols(symbol,from="2004-11-02",to="2005-10-26")  # does not work

Regards

Robert

-----Mensagem Original----- 
From: Andreas Voellenklee
Sent: Friday, October 28, 2011 3:12 AM
To: R-SIG-Finance at r-project.org
Subject: [R-SIG-Finance] Fwd: blotter, quantstrat: initDate without effect?

Hi,
I spend the last couple of days trying out the functionality of the
TradeAnalytics packages. There are some observations that I would like
to share. I use RStudio as GUI and derived the attached code from a
demo example.

1) since the trading system operates with moving averages, I download
data prior the start of applying the strategy to have all moving
averages calculated at the start time. But although the Portfolio,
Account and Orders get initialized at the beginning of 2002, the
execution of the strategy seems to start from the beginning of 2001

2) the getSymbols command returns a warning I don't understand:

Warning message:
In if (as.character(sc[[1]]) != calling.fun) return() :
the condition has length > 1 and only the first element will be used:

This is my sessionInfo:

> sessionInfo()
R version 2.13.1 (2011-07-08)
Platform: i686-pc-linux-gnu (32-bit)

locale:
[1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C
LC_TIME=de_DE.UTF-8        LC_COLLATE=en_US.UTF-8
[5] LC_MONETARY=C              LC_MESSAGES=en_US.UTF-8
LC_PAPER=de_DE.UTF-8       LC_NAME=C
[9] LC_ADDRESS=C               LC_TELEPHONE=C
LC_MEASUREMENT=de_DE.UTF-8 LC_IDENTIFICATION=C

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base

other attached packages:
[1] PerformanceAnalytics_1.0.3.2 quantstrat_0.5.6
blotter_0.8.4                FinancialInstrument_0.7.5
[5] quantmod_0.3-17              Defaults_1.1-1
TTR_0.21-0                   xts_0.8-2
[9] zoo_1.7-5

loaded via a namespace (and not attached):
[1] grid_2.13.1     lattice_0.19-30 tools_2.13.1


Regards,
Andreas






_______________________________________________
R-SIG-Finance at r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-sig-finance
-- Subscriber-posting only. If you want to post, subscribe first.
-- Also note that this is not the r-help list where general R questions 
should go.



More information about the R-SIG-Finance mailing list