| Ord | Topic | Category | Author | Date |
|---|---|---|---|---|
| Loading... (need help?) |
VSI Series
about
vsi
reading
List of Very Short Introduction Books.
List of VSI Books
Source: Wikipedia.org
Page created dynamically using Listing 1.
import pandas as pd
import re
from itables import show, init_notebook_mode
# init_notebook_mode(all_interactive=True)
df = pd.read_html(
'https://en.wikipedia.org/wiki/List_of_Very_Short_Introductions_books')
df = df[0]
df.columns = ['Ord', 'Topic', 'Author', 'Date' ,'drop', 'Category']
df = df.drop(columns='drop')
# fix date
pattern = r"\d{1,2} \w+ \d{4}( \d{1,2} \w+ \d{4}) \(2nd ed\.\)"
replacement = r"\1"
df['Date'] = df['Date'].apply(lambda x: re.sub(pattern, replacement, x))
# re order
df = df[['Ord', 'Topic', 'Category', 'Author', 'Date']]
show(df, caption='Table of VSI books.',
classes="display nowrap compact",
lengthMenu=[25, 50, 100, -1])