Overall Statistics
Total Orders
0
Average Win
0%
Average Loss
0%
Compounding Annual Return
0%
Drawdown
0%
Expectancy
0
Start Equity
100000.00
End Equity
100000
Net Profit
0%
Sharpe Ratio
0
Sortino Ratio
0
Probabilistic Sharpe Ratio
0%
Loss Rate
0%
Win Rate
0%
Profit-Loss Ratio
0
Alpha
0
Beta
0
Annual Standard Deviation
0
Annual Variance
0
Information Ratio
-2.749
Tracking Error
0.098
Treynor Ratio
0
Total Fees
$0.00
Estimated Strategy Capacity
$0
Lowest Capacity Asset
Portfolio Turnover
0%
# region imports
from AlgorithmImports import *
# endregion

class EurexEuroStoxx50Test(QCAlgorithm):

    def __init__(self):        
        self._traded = False
        self._index: Index = None

    def initialize(self):
        self.set_start_date(2024, 1, 1)
        self.set_end_date(2024, 2, 1)

        resolution = Resolution.MINUTE if self.live_mode else Resolution.HOUR
        
        self._index = self.add_index("SX5E", Resolution.HOUR, market=Market.EUREX)

        history = self.history(self._index.symbol, 1000, Resolution.MINUTE)
        self.log(f"Fetched {history.shape[0]} historical minute data points")
        self.log(str(history.iloc[:10] ))

        # self.set_warm_up(30, Resolution.DAILY)
       
    def on_warmup_finished(self):
        # self.log(f"[{self.time}] :: OnWarmupFinished(): Index Price: {self._index.price}")
        pass

    def on_data(self, slice: Slice):
        if self.is_warming_up: 
            return
        
        data_str = "\n".join([f"[{SecurityType(data.symbol.security_type)}] [{data.symbol.value}] {data}" for data in slice.all_data])
        self.log(f"[{self.time}] :: Data:\n{data_str}")