However, you do need to have a way of isolating that subtree. My
method will allow you to isolate that particular subtree, the whole
tree will be there if you need it, but any operation you would like to
perform will be on only that tree. So for example, the following code:
tables = soup("table")
t1 = tables[0] #gives you the first table in the html
trs = t1("tr") #gives you a list of all rows in that particular table,
not the whole file
and so on. Certainly you can use regex the same way as my examples.