def convert_wiki_to_table(wiki_text, n_table=0): html_text = pypandoc.convert(wiki_text, 'html', 'mediawiki') tables = pandas.read_html(html_text) return tables[n_table]