Hello everyone,
I am a new user coming from the recent Quantopian shutdown. I would often use the Quantopian Notebooks for backtesting purposes. they had a QGrid implementation that would format the results from a pipeline in an easy to read grid. It would keep everything neatly organized and would allow you to scroll through the results. It would look something like this:
| Date | Symbol | (NameOfFundamental) | (NameOfFundamental) | etc...
| Date | Symbol | (FundamentalValue) | (FundamentalValue) | etc...
| Date | Symbol | (FundamentalValue) | (FundamentalValue) | etc...
Does Quantconnect have a similar feature? I have come across the standard dataframe, but I am not familiar with how to edit the columns and rows to show something similar to what is shown above. I am going to include the code from my notebook so you can see what I have come up with.
I really appreciate any help and guidance!
from clr import AddReference
AddReference("System")
AddReference('System.Memory')
AddReference("QuantConnect.Common")
AddReference("QuantConnect.Research")
AddReference("QuantConnect.Indicators")
from System import *
from QuantConnect import *
from QuantConnect.Data.Market import TradeBar, QuoteBar
from QuantConnect.Research import *
from QuantConnect.Indicators import *
from datetime import datetime, timedelta
import matplotlib.pyplot as plt
import pandas as pd
# Create an instance
qb = QuantBook()
tickers = [
"MSFT",
"AAPL",
"NVDA",
"INTC"
]
symbols = [qb.AddEquity(ticker, Resolution.Daily).Symbol for ticker in tickers]
start_date = datetime(2010, 1, 4)
end_date = datetime(2010, 1, 5)
data = qb.GetFundamental(symbols, "ValuationRatios.PERatio", start_date, end_date)
print(data)
*Also, the symbols across the top have what looks like some form of ID (Ex: R735QTJ8XC9X) How do you get rid of this? Thank you guys so much!