LOR.get_url¶
- LOR.get_url(prefix)[source]¶
Generates the URL for the given PRIDE/LOR code prefix.
This method constructs the appropriate webpage URL based on the provided prefix, ensuring that it is valid before appending the correct suffix.
- Parameters:
prefix (str) – The PRIDE/LOR code prefix.
- Returns:
A fully constructed URL corresponding to the given prefix.
- Return type:
str
Examples:
>>> from pyrcs.line_data import LOR # from pyrcs import LOR >>> lor = LOR() >>> lor.get_url(prefix='CY') 'http://www.railwaycodes.org.uk/pride/pridecy.shtm' >>> lor.get_url(prefix='CA') Traceback (most recent call last): ... AssertionError: `prefix` must be one of ['CY', 'EA', 'GW', 'LN', 'MD', 'NW', 'NZ', ...