The process of evaluating a strategy, theory, or model by applying it to historical data.

learn more… | top users | synonyms (1)

3
votes
3answers
265 views

How to most optimally perform currency conversions when backtesting on portfolio level?

I am currently expanding my own strategy profiling and testing platform which partly consists of a portfolio backtesting module. The backtest engine processes tick based data (quotes for currencies, ...
3
votes
1answer
3k views

t-statistics for the mean return, using Newey-West standard errors

I have seen that in several papers, where the aim was to evaluate the performance of a certain investment strategy, they use t-statistics to test for significance in the results. However, this seems a ...
3
votes
1answer
340 views

analyze strategy performance with given matrix of weights/time and weekly returns in R

I have a matrix of 259 weekly returns, 50 assets and a portfolio composition for each of the 259 weeks. I would like to test the performance of the portfolio during 52 weeks, rebalancing every 12 ...
3
votes
2answers
1k views

How to account for bid/ask spread when backtesting?

I'm backtesting an algorithm for trading nasdaq stocks, and would like to take into account the spread. I am using historical data from yahoo, which contains: open, high, low, close, volume, adj. ...
3
votes
1answer
199 views

How to design back-testing (validation) for such modified Vasicek model?

Consider a classical Black Scholes model , $$\frac{dS}{S} = \mu dt + \sigma dW$$ , where $dW$ is a Brownian motion, that $W(t_1) - W(t_0) \sim N(0, t_1 - t_0)$. The back-testing strategy is ...
3
votes
1answer
272 views

How do you estimate the capacity of a strategy from historical data?

What are some good ways to estimate the capacity of a strategy from historical data (including full market depth)? Obviously, a naive approach is that you want the strategy's returns to exceed its ...
3
votes
1answer
888 views

What latency should I use for backtesting a high-frequency strategy?

We're developing an HFT strategy for highly liquid futures traded at Eurex. We are planning to colocate our server and to use data feed of QuantHouse and execution API of ObjectTrading. Backtesting is ...
3
votes
1answer
353 views

Cross Bid and Ask prices for Forex trading

I am using ITCH protocol to get the Market Data information for Forex and trying to implement LOB on it and what i have noticed is that Bid and Ask prices are crossing very often. Should that be ...
3
votes
1answer
1k views

How do I backtest a convertible bond arbitrage strategy in R/Matlab?

Since no one was able to answer my previous question, I am going to try to backtest a modern convertible bond arbitrage strategy myself (perhaps I'll report the results back here, if you're lucky :)). ...
3
votes
1answer
313 views

How do I backfill the price of bonds for backtesting?

I need to backfill the price of bonds for testing a startegy. The method employed is: Regressing the YTM of the bond against a benchmark. Using the regression estimates to calculate the YTM for the ...
3
votes
0answers
106 views

What is the most convenient data structure for backtesting a model of futures options prices?

I have an empirical model for the dynamics of futures prices in a particular market that I have implemented using a long series of the front five contracts. (I account for the roll in my model.) I ...
3
votes
0answers
425 views

Testing Valuation, Size and Momentum (proprietary factors) from 1988-2013: No evidence of driving cross-sectional returns

I am currently testing whether three proprietary factors - Valuation, Size and Momentum - explain cross-sectional returns. A sample of 3000 securities was tested using Fama-MacBeth two-pass ...
3
votes
0answers
237 views

Quant/Stat Factor Performance Website/Distribution?

Does anyone know of a decent quant/stat factor website, distribution(public or private) or publication that tracks performance of "many" of traditional quant/stat factors? By that I mean would show ...
3
votes
2answers
431 views

Volatility of a rolling window strategy

What methods can be applied to determine the volatility of strategy using a rolling window? Using normal standard deviation would bias the results as the returns will be highly correlated. Although, ...
3
votes
0answers
118 views

Are there canonical test cases for testing of pricing engines

Short intro: We are developing pricing engines for the calculation of market risk in a Solvency II solution, including bonds, callable bonds, cds, options, futures and so on. Are there any canonical ...
2
votes
2answers
1k views

Resequencing of MsgSeqNum in FIX 4.2

I am trying to achieve the following functionality using QuickFIX for FIX 4.2 Send a couple of orders and make sure they’re filled. Then disconnect. Change the incoming (from Broker) sequence number ...
2
votes
2answers
944 views

backtesting options strategies in R

I would like to backtest an options strategy in R. I require the ability to delta hedge and rebalance to options in the portfolio at different frequencies (daily, monthly,etc.) What packages are the ...
2
votes
1answer
420 views

What are the advantages of knowing the bid and ask over the best bid and ask?

I am importing historical intraday tick data from Bloomberg and I noticed the Bloomberg API allows users to import best bid, best ask, bid, and ask prices If I am backtesting a trading strategy, what ...
2
votes
2answers
176 views

Backtesting Period

Views on timeframes for backtesting vary considerably. Curious on what timeframe/trade size leads to a statistically significant result. For example, what backtest period is reasonable for a system ...
2
votes
2answers
137 views

How to select optimal betting strategy from backtest?

I have written a model for predicting the winner of UFC fights. My model calculates the probability of each fighter to win a given match. I have back tested the model and found it to be very ...
2
votes
1answer
102 views

Aftcast Generation

Aftcast is a way of simulating equity curves for different start years, usually from a large sample data ~100 years. Its kind of like start date sensitivity testing but in my case, I incorporated ...
2
votes
1answer
184 views

backtesting a 5% quantile model of a discrete value random variable?

If a random variable is discrete, and we are interested in its quantile value, how to define a proper back testing procedure? For example, the underlying variable with a discrete value is $$ ...
2
votes
1answer
239 views

desk's performance

I need your point of view in evaluating the monthly performance of a desk. I have the daily credit risk capital requirement (A); the net banking income or GNP (B). What is the best measure of ...
2
votes
1answer
41 views

Overlapping Value-at-Risk Backtest Data an Issue?

My understanding of VaR model back testing is thus: ~~ t: Calculate daily VaR using look back data over n past days t+1: Compare daily return against VaR, record breach if one occurred, repeat ...
2
votes
1answer
39 views

How to compute daily compounded backtest returns closer to real-world results?

I often run quick tests of trading strategies in my analytics suites by: multiplying a vector of signal (lagged, {-1,0,1}) with a time series of daily percentage returns doing a cumulative product ...
1
vote
3answers
216 views

Handling Missing values in stocks returns when estimating the co variance matrix

What is the best way to handle missing values when stocks did not exist for the entire historical period?.
1
vote
1answer
366 views

Is making a bid/ask offer a good way to lower the spreads?

I have written an algorithmic trading program which relies heavily on low spreads in the 0.1-0.3 PIP region. I was now wondering if it would be a good idea to place bid/ask offers instead of limit ...
1
vote
2answers
462 views

One bar look-ahead backtesting

Suppose you backtest the EUR/USD (or GBP/USD) forex pair with this system on the 1min timeframe: 1) Enter the market at any time n: go long if the "future" bar n+1 has a higher close as the close ...
1
vote
1answer
101 views

Analog - Pattern Recognition model using KNN

I'm building a pattern recognition model for my master thesis. The idea is to build a framework with some Macro variables (long/short term rates; rates differential; equity; fx; vix) in order to find ...
1
vote
2answers
210 views

Backtesting with Simulated Historical Data?

The trading strategies that are going to backtest well are the ones that pick the winners from the past. For example, if a trading strategy simply bought apple stock it would backtest extremely well. ...
1
vote
2answers
350 views

Machine Learning on matlab 2010

I am trying to develop a trading model. It uses certain technical and fundamental features and the model learns from the past. I have a 3-class output - bullish, neutral and bearish. On trying neural ...
1
vote
2answers
113 views

how to make a distribution model tolerable of trend?

I'm building an model on different loans' NPL rate. The problem is NPL rates are always affected by the market. When NPL rates move in trend, my model will fail the back-testing. Assuming $x(t)$ is a ...
1
vote
0answers
16 views

Adjusting for your own orders in future backtests

I was asked this question in an interview and despite thinking about it for a while, I haven't been able to come up with a good answer. Suppose you have a strategy you are running where at certain ...
1
vote
1answer
103 views

Plot Evolution of portfolio weights over time in R [closed]

Is there any function for plotting the evolution of portfolio weights over time in r?. I have a matrix of portfolio weights from an equal weighting strategy at rebalancing times and want to plot ...
1
vote
0answers
218 views

Comparing Backtests of Value-at-Risk and Expected Shortfall

My goal is to test if ES (CVaR) empirically is a better risk measure than VaR for a set of given variables (assumed underlying distribution, confidence level, sample size) for different asset classes. ...
1
vote
0answers
167 views

Backtesting benchmark / control test design

I am designing a backtesting system to test an algorithm. I'd like to have a benchmark / control test results to compare to the results of a custom algorithm. A limited "set" of stocks is selected ...
1
vote
0answers
280 views

VaR backtesting with overlapping time intervals

Of course the issue here is dependence: can it be removed or accounted for (in independence tests too, which of course would be troublesome)? There's a lot of literature on regression in this setting, ...
0
votes
2answers
131 views

Sharpe Ratio and time spent in loss

Is it possible to express, given an annualized Sharpe Ratio value, what is an expected maximum/average time spent in a draw-down or something in this manner? E.g. with SR of 10, you'd expect to spend ...
0
votes
1answer
79 views

What data should be used for regression-based model backtesting?

I ran regressions using historical valuation data and now want to backtest the models I came up with. Are there any issues with using the same historical data set for the backtest that I need to be ...
0
votes
1answer
84 views

How do I take an unbiased, sector neutral sample from a stock index?

I am looking to take a cross sector subset of a larger stock index universe. What steps to I take to assure that sector representation is as equal as possible to help smooth out my variance(while ...
0
votes
2answers
46 views

Long/Short Backtesting Set up

I am going to be backtesting a Long/Short equity strategy and need some guidance on how best to deal with the short book. I was thinking that for each portfolio I would go long 50 equities and go ...
0
votes
1answer
119 views

How to backtest the VaR model?

I have a sorted historical P&L vector of 250 days and say, I want to calculate the 90% VaR on this distribution. I will look for the 225 element (90% * 250 = 225) and this will be my Value at ...
0
votes
1answer
347 views

backtesting with open, close, high and low

I am quite notice at the business of backtesting for an automated strategy. I was wondering, can I/should I use High and Low for this purpose? On one hand, the algorithm will see these prices, but on ...
0
votes
0answers
22 views

Calculation of Returns and Risk Metrics for L/S Portfolio

I am trying to build a test for a long/short portfolio. I am aiming for market neutral and have put together a long portfolio as well as a short portfolio (see below). However, I am not sure if I am ...
0
votes
0answers
72 views

How to calculate returns of backtested strategy?

Lets say I have some strategy (long/short) backtested for certain period. Strategy has entries/exits only at the end of the day and may have overnight positions hold. Now I would like to compare ...
0
votes
0answers
124 views

How to fully replicate ADX + DI Indicators in Excel?

For black box testing, I was hoping that I could replicate the ADX + DI+ and DI- indicators that are provided in trading platforms such as ThinkOrSwim, ScottradeElite etc. However, I noticed that ...
0
votes
0answers
320 views

Backtesting with fundamentals

Recently I've read some books about quantative approach to fundamental investing: - What works on Wall Street - James O'Shaughnessy - Quantitative Value - Wesley Gray, Tobias Carlisle - Quantitative ...
0
votes
1answer
194 views

adjusted close prices on SP500

When I look at the adjusted close prices of SP500, for example, I notice that the numbers are always significantly below the actual closing. In the explanation of what adjusted prices are, one gets ...
0
votes
1answer
164 views

How far back is normal to backtest an ATS ? [duplicate]

Possible Duplicate: How much data is needed to validate a short-horizon trading strategy? How far back do people usually backtest trading systems? months? years?
0
votes
0answers
40 views

Inferring Returns From Minimal Data Points [duplicate]

Possible Duplicate: How much data is needed to validate a short-horizon trading strategy? Suppose I have daily returns for a trading strategy against one month of data. Before starting ...