netzschleuder
list_netzschleuder_records
¶
Read a list of data sets available at the netzschleuder repository.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
base_url
|
str
|
Base URL of netzschleuder repository |
'https://networks.skewed.de'
|
**kwargs
|
typing.Any
|
Keyword arguments that will be passed to the netzschleuder repository as HTTP GET parameters. For supported parameters see https://networks.skewed.de/api |
{}
|
Examples:
Return a list of all data sets
>>> import pathpyG as pp
>>> pp.io.list_netzschleuder_records()
['karate', 'reality_mining', 'sp_hypertext', ...]
Return a list of all data sets with a given tag
Return a dictionary containing all data set names (keys) as well as all network attributes
Returns:
Type | Description |
---|---|
typing.Union[list, dict]
|
Either a list of data set names or a dictionary containing all data set names and network attributes. |
Source code in src/pathpyG/io/netzschleuder.py
read_netzschleuder_graph
¶
Read a pathpyG graph or temporal graph from the netzschleuder repository.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
name
|
str
|
Name of the network data set to read from |
required |
net
|
typing.Optional[str]
|
Identifier of the network within the data set to read. For data sets containing a single network only, this can be set to None. |
None
|
ignore_temporal
|
If False, this function will return a static or temporal network depending on whether edges contain a time attribute. If True, pathpy will not interpret time attributes and thus always return a static network. |
required | |
base_url
|
str
|
Base URL of netzschleuder repository |
'https://networks.skewed.de'
|
format
|
for 'csv' a zipped csv file will be downloaded, for 'gt' the binary graphtool format will be retrieved via the API |
'csv'
|
Examples:
Read network '77' from karate club data set
>>> import pathpyG as pp
>>> n = pp.io.read_netzschleuder_network('karate', '77')
>>> print(type(n))
>>> pp.plot(n)
pp.Graph
Returns:
Type | Description |
---|---|
pathpyG.core.graph.Graph
|
an instance of Graph |
Source code in src/pathpyG/io/netzschleuder.py
93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 |
|
read_netzschleuder_record
¶
Read metadata of a single data record with given name from the netzschleuder repository
Parameters:
Name | Type | Description | Default |
---|---|---|---|
name
|
str
|
Name of the data set for which to retrieve the metadata |
required |
base_url
|
str
|
Base URL of netzschleuder repository |
'https://networks.skewed.de'
|
Examples:
Retrieve metadata of karate club network
>>> import pathpyG as pp
>>> metdata = pp.io.read_netzschleuder_record('karate')
>>> print(metadata)
{
'analyses': {'77': {'average_degree': 4.52... } }
}
Returns:
Type | Description |
---|---|
dict
|
Dictionary containing key-value pairs of metadata |