Hi all,

I am re-implementing my code @ Quantopian on QC platform.  Below is a simple code snippet, where I am calculating future spread and ratio for NGH19/NGJ19.  Could anyone direct me on how to implement this using QC APIs? while I am comfortable with Quantopian libs/APIs, I am still trying to understand how to work with futures on QC.  

front_contract = "NGH19"
back_contract = "NGJ19"
contracts = symbols([front_contract, back_contract])
prices = get_pricing(contracts,

prices.columns = map(lambda x: x.symbol, prices.columns)
prices = prices.dropna()
spread = prices[front_contract] - prices[back_contract]
ratio = prices[front_contract] / prices[back_contract]

Thanks in advance!