get_introduction

pyrcs.parser.get_introduction(url, delimiter='\n', verbose=True)

Get contents of the Introduction page.

Parameters
  • url (str) – URL of a web page (usually the main page of a data cluster)

  • delimiter (str) – delimiter used for separating paragraphs, defaults to '\n'

  • verbose (bool or int) – whether to print relevant information in console, defaults to True

Returns

introductory texts on the given web page

Return type

str

Examples:

>>> from pyrcs.parser import get_introduction

>>> bridges_url = 'http://www.railwaycodes.org.uk/bridges/bridges0.shtm'

>>> intro_text = get_introduction(url=bridges_url)
>>> intro_text
"There are thousands of bridges over and under the railway system. These pages attempt to...