aequilibrae.project.network.Period#

class aequilibrae.project.network.Period(dataset, project)[source]#

A Period object represents a single record in the periods table

>>> project = create_example(project_path, "coquimbo")

>>> all_periods = project.network.periods

# We can just get one link in specific
>>> period1 = all_periods.get(1)

# We can find out which fields exist for the period
>>> which_fields_do_we_have = period1.data_fields()
__init__(dataset, project)[source]#

Methods

__init__(dataset, project)

connect_db()

data_fields()

Lists all data fields for the period, as available in the database

renumber(new_id)

Renumbers the period in the network

save()

Saves period to database

connect_db()#
data_fields() list[source]#

Lists all data fields for the period, as available in the database

Returns:

data fields (list): list of all fields available for editing

renumber(new_id: int)[source]#

Renumbers the period in the network

Logs a warning if another period already exists with this period_id

Arguments:

new_id (int): New period_id

save()[source]#

Saves period to database