IO
read_csv(fname=None, header=False, index=False, t_col=2)
Read temporal edgelist and store it in a dictionary. Parameters: fname: directory of a dataset in .csv format or data object created from loading dgb/tgb datasets header: whether first line of data file is header index: whether the first column is row indices t_col: column indext for timestamps (0 or 2) ts_sorted: if data are sorted based on timestamp
Returns:
Name | Type | Description |
---|---|---|
temp_edgelist |
dict
|
A dictionary of edges and their frequency at each time interval |
Source code in tgx/io/read.py
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 |
|