Skip to content

jackgurae/statarb

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

1. Introduction

This is a simple project to demonstrate how does pairs trading works in daily timeframe

  1. Introduction
  2. Data

2. Data

SET50 daily data from retrived from yahooquery package

3. Pairs Trading concept

Pairs trading is a market neutral trading strategy enabling traders to profit from virtually any market conditions: uptrend, downtrend, or sideways movement.

This strategy is categorized as a statistical arbitrage and convergence trading strategy.

The strategy monitors performance of two historically correlated securities. When the correlation between the two securities temporarily weakens, i.e. one stock moves up while the other moves down, the pairs trade would be to short the outperforming stock and to long the underperforming one, betting that the “spread” between the two would eventually converge.

The divergence within a pair can be caused by temporary supply/demand changes, large buy/sell orders for one security, reaction for important news about one of the companies, and so on.

Note: this description is mostly generated by Github Copilot.# statarb

4. How to run streamlit app

  1. Install streamlit
pip install streamlit
  1. Run streamlit app
streamlit run ./streamlit/pairs_trade_app.py   

About

Stat Arbitrage

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published