HI Everyone! I am very new to QuantConnect and having problems with my first algorithm.

I get the error: "BacktestingRealTimeHandler.Run(): There was an error in a scheduled event SPY: EveryDay: SPY: 20 min after MarketOpen. The error was TypeError : No method matches given arguments for History"  when I try to run the following code:
 

import numpy as np

class QuantumModulatedPrism(QCAlgorithm):

def Initialize(self):
self.SetCash(100000)
self.SetStartDate(2019,9,1)
self.SetEndDate(2020,12,1)

self.symbol = self.AddEquity("SPY", Resolution.Daily).Symbol

self.Debug(self.symbol)
self.Log(self.symbol)

self.lookback=20

self.ceiling,self.floor=30,10

self.initialStopRisk=0.98
self.trailingStopRisk=0.9

self.Schedule.On(self.DateRules.EveryDay(self.symbol),\
self.TimeRules.AfterMarketOpen(self.symbol,20),\
Action(self.EveryMarketOpen))



def OnData(self, data):
self.Plot("Data Cahart", self.symbol, self.Securities[self.symbol].Close)


def EveryMarketOpen(self):

close=self.History(self.symbol, 31, Resolution.Daily)["close"]
todayvol = np.std(close[1:31])
yesterdayvol=np.std(close[0:30])
deltavol = (todayvol-yesterdayvol)/todayvol

self.lookback = self.lookback*(1+deltavol)

if self.lookback>self.ceiling:
self.lookback = self.ceiling
elif self.lookback<self.floor:
self.lookback=self.floor

self.high = self.History(self.symbol, self.lookback, Resolution.Daily)["high"]

if not self.Securities[self.symbol].Invested and \
self.Securities[self.symbol].Close >= max(self.high[:-1]):
self.SetHoldings(self.symbol, 1)
self.brakeoutlvl = max(self.high[:-1])
self.highestPrice = self.breakoulvl

if self.Securities[self.symbol].Invested:
if not self.Transactions.GetOpenOrders(self.symbol):
self.stopMarketTicket= self.StopMarketOrder(self.symbol, \
-self.Protfolio[self.symbol].Quantity, \
self.initialStopRisk*self.breakoutlvl)

if self.Securities[self.symbol].Close>self.highestPrice and \
self.initalStopRisk*self.breakoutlvl < self.Securities[self.symbol].Close*self.trailingStopRisk:
self.highestPrice=self.Securities[self.symbol].Close
updateFields=UpdateOrderFields()
updateFields.StopPrice=self.Securities[self.symbol].Close*self.trailingStopRisk
self.stopMarketTicket.Update(updateFields)

self.Debug(updateFields.StopPrice)

self.Plot("Data Chart", "Stop Price", self.stopMarketTicket.Get(OrderField.StopPrice))

I get the error when the scheduler is executed, but I have no clue why do I get it. 
Thank you in advance for your help and support!