Josh,

Your comment on the indicator makes sense.  I already have it as a column
in my dataFrame, so I guess that I can just pass that column name when
creating a signal.

The strategy is a *single asset* with OHLC each minute.  I have a few
custom indicators that are pre-calculated.  Just need to test a bunch of
signals and rules around those indicators and close price.  Do I need to do
anything special to have the dataFrame setup correctly for quantstrat?

Thanks!


On Fri, Mar 14, 2014 at 8:52 AM, Joshua Ulrich <josh.m.ulrich@gmail.com>wrote:

> On Fri, Mar 14, 2014 at 10:30 AM, Noah Silverman <noahsilverman@ucla.edu>
> wrote:
> >
> > Hi,
> >
> > Working on developing a complex portfolio and backtesting strategy.
> > >From what I've read, the quantstrat package looks ideal for working
> > through the ideas.
> >
> > Two questions:
> >
> > 1) I have an indicator that is pre-calculated.  (From a bunch of
> > complicated functions and outside data.)  I'd like to simply pass the
> > vector of values into quantstrat, but can't figure out how to do that.
> > The function to add a signal appears to only accept functions, not
> > data.  Is there a way for me to do this?
> >
> If it needed a function and there was no way to pass data, you could
> wrap your data in a function.
> datafun <- function(...) mydata
>
> But nothing *requires* that you call/use add.indicator().  Simply
> merge your indicator with your market data.
>
> > 2) Along the lines of #1 above:  I have my financial data directly from
> > a vendor.  It already has OHLC defined.  Can I simply pass this to
> > quanstrat?  If so, what is the proper order/formant/naming of columns to
> > make quanstrat happy?
> >
> That depends on the specifics of the strategy you're trying to build,
> which you haven't provided.
>
> > Thanks!
> >
> > --
> > *Noah Silverman, PhD* | UCLA Department of Statistics
> > 8117 Math Sciences Building, Los Angeles, CA 90095
> >
>
> --
> Joshua Ulrich  |  about.me/joshuaulrich
> FOSS Trading  |  www.fosstrading.com
>

	[[alternative HTML version deleted]]

