find_year

find_year(text)

Extract year from 1940 till 2020.

Parameters

text: str Text selected to apply transformation

Examples:

sentence="India got independence on 1947."
find_year(sentence)
    >>> ['1947']