Trouble parsing tabular items from a graph located in a website
You'll be much better off querying the website's backend directly than using selenium to scrape the frontend for three important reasons:
Speed: Using the API directly is much, much faster and efficient because it only fetches the data you need and doesn't have to wait for javascript to run or pixels to render, and there is no overhead of running a webdriver.
Stability: usually changes to the frontend are much more frequent and hard to follow than changes to the backend. If your code relies on the site's frontend it will probably stop working pretty quickly when they make some UI changes.
Accuracy: sometimes the data displayed in the UI is inaccurate or incomplete. For example, in this website, all numbers are rounded to two decimal points, while the backend sometime provides data more than twice as accurate.
Here's how you could easily use the backend API:
import requests
# API url found using chrome devtools
url = 'https://www.marketscreener.com/charting/afDataFeed.php?codeZB=6491453&t=eec&sub_t=bna&iLang=2'
# We are mocking a chrome browser because the API is blocking python requests apparently
headers = {'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/76.0.3809.100 Safari/537.36'}
# Make a request to the API and parse the JSON response
data = requests.get(url, headers=headers).json()[0]
# A function to find data for a specific date
def get_vals(date):
vals = []
for items in data:
for item in items:
if item['t'] == date:
vals.append(item['y'])
break
return vals
# Use the function above with the example table given in the question
print(get_vals('Thursday, Aug 22, 2019'))
Running this outputs the list [0.9, 0.84678, 0.76628, 0, 7, 0]
, which as you can see is the data you wanted to extract from the table you gave as an example.