Skip to content

Commit 62aec6c

Browse files
InterdisciplinaryPhysicsTeampitmonticoneClaudMor
committed
Update docstrings
Co-Authored-By: Pietro Monticone <[email protected]> Co-Authored-By: Claudio Moroni <[email protected]>
1 parent fd2ef21 commit 62aec6c

File tree

2 files changed

+15
-15
lines changed

2 files changed

+15
-15
lines changed

docs/src/API.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ multiplex_interlayer(
114114
default_edge_metadata::Function = (x,y) -> NamedTuple(),
115115
transfer_vertex_metadata::Bool = false,
116116
name::Symbol = Symbol("interlayer_$(layer_1.name)_$(layer_2.name)")
117-
) where {T<:Integer, U <: Real, G<:AbstractGraph{T}} = _multiplex_interlayer(collect(mv_vertices(layer_1)), collect(mv_vertices(layer_2)), null_graph, U; default_edge_weight = default_edge_weight, default_edge_metadata = default_edge_metadata, transfer_vertex_metadata = transfer_vertex_metadata , name = name)
117+
) where {T<:Integer, U <: Real, G<:AbstractGraph{T}}
118118
119119
120120
empty_interlayer(

src/subgraphs/interlayer.jl

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -298,16 +298,16 @@ Return an `Interlayer{T,U,G}` that has edges only between vertices that represen
298298
299299
# ARGUMENTS
300300
301-
-`layer_1::Layer{T,U}`: one of the two layers connected by the Interlayer;
302-
-`layer_2::Layer{T,U}`: one of the two layers connected by the Interlayer;
303-
`null_graph::G`: the Interlayer's underlying graph type, which must be passed as a null graph. If it is not, an error will be thrown.
301+
- `layer_1::Layer{T,U}`: one of the two layers connected by the Interlayer;
302+
- `layer_2::Layer{T,U}`: one of the two layers connected by the Interlayer;
303+
- `null_graph::G`: the Interlayer's underlying graph type, which must be passed as a null graph. If it is not, an error will be thrown.
304304
305305
# KWARGS
306306
307-
-`default_edge_weight::Function`: Function that takes a pair of `MultilayerVertex`s and returns an edge weight of type `weighttype` or `nothing` (which is compatible with unweighted underlying graphs and corresponds to `one(weighttype)` for weighted underlying graphs). Defaults to `(src, dst) -> nothing`;
308-
-`default_edge_metadata::Function`: Function that takes a pair of `MultilayerVertex`s and returns a `Tuple` or a `NamedTuple` containing the edge metadata, that will be called when `add_edge!(mg,src,dst, args...; kwargs...)` is called without the `metadata` keyword argument, and when generating the edges in this constructor. Defaults to `(src, dst) -> NamedTuple()`;
309-
-`name::Symbol`: The name of the Interlayer. Defaults to Symbol("interlayer_(layer_1.name)_(layer_2.name)");
310-
-`transfer_vertex_metadata::Bool`:if true, vertex metadata found in both connected layers are carried over to the vertices of the Interlayer. NB: not all choice of underlying graph may support this feature. Graphs types that don't support metadata or that pose limitations to it may result in errors.;
307+
- `default_edge_weight::Function`: Function that takes a pair of `MultilayerVertex`s and returns an edge weight of type `weighttype` or `nothing` (which is compatible with unweighted underlying graphs and corresponds to `one(weighttype)` for weighted underlying graphs). Defaults to `(src, dst) -> nothing`;
308+
- `default_edge_metadata::Function`: Function that takes a pair of `MultilayerVertex`s and returns a `Tuple` or a `NamedTuple` containing the edge metadata, that will be called when `add_edge!(mg,src,dst, args...; kwargs...)` is called without the `metadata` keyword argument, and when generating the edges in this constructor. Defaults to `(src, dst) -> NamedTuple()`;
309+
- `name::Symbol`: The name of the Interlayer. Defaults to Symbol("interlayer_(layer_1.name)_(layer_2.name)");
310+
- `transfer_vertex_metadata::Bool`:if true, vertex metadata found in both connected layers are carried over to the vertices of the Interlayer. NB: not all choice of underlying graph may support this feature. Graphs types that don't support metadata or that pose limitations to it may result in errors.;
311311
"""
312312
multiplex_interlayer(
313313
layer_1::Layer{T,U},
@@ -375,16 +375,16 @@ Construct an empty interlayer (i.e. an interlayer with no edges).
375375
376376
# ARGUMENTS
377377
378-
-`layer_1::Layer{T,U}`: one of the two layers connected by the Interlayer;
379-
-`layer_2::Layer{T,U}`: one of the two layers connected by the Interlayer;
380-
`null_graph::G`: the Interlayer's underlying graph type, which must be passed as a null graph. If it is not, an error will be thrown.
378+
- `layer_1::Layer{T,U}`: one of the two layers connected by the Interlayer;
379+
- `layer_2::Layer{T,U}`: one of the two layers connected by the Interlayer;
380+
- `null_graph::G`: the Interlayer's underlying graph type, which must be passed as a null graph. If it is not, an error will be thrown.
381381
382382
# KWARGS
383383
384-
-`default_edge_weight::Function`: Function that takes a pair of `MultilayerVertex`s and returns an edge weight of type `weighttype` or `nothing` (which is compatible with unweighted underlying graphs and corresponds to `one(weighttype)` for weighted underlying graphs). Defaults to `(src, dst) -> nothing`;
385-
-`default_edge_metadata::Function`: Function that takes a pair of `MultilayerVertex`s and returns a `Tuple` or a `NamedTuple` containing the edge metadata, that will be called when `add_edge!(mg,src,dst, args...; kwargs...)` is called without the `metadata` keyword argument, and when generating the edges in this constructor. Defaults to `(src, dst) -> NamedTuple()`;
386-
-`name::Symbol`: The name of the Interlayer. Defaults to Symbol("interlayer_(layer_1.name)_(layer_2.name)");
387-
-`transfer_vertex_metadata::Bool`:if true, vertex metadata found in both connected layers are carried over to the vertices of the Interlayer. NB: not all choice of underlying graph may support this feature. Graphs types that don't support metadata or that pose limitations to it may result in errors.;
384+
- `default_edge_weight::Function`: Function that takes a pair of `MultilayerVertex`s and returns an edge weight of type `weighttype` or `nothing` (which is compatible with unweighted underlying graphs and corresponds to `one(weighttype)` for weighted underlying graphs). Defaults to `(src, dst) -> nothing`;
385+
- `default_edge_metadata::Function`: Function that takes a pair of `MultilayerVertex`s and returns a `Tuple` or a `NamedTuple` containing the edge metadata, that will be called when `add_edge!(mg,src,dst, args...; kwargs...)` is called without the `metadata` keyword argument, and when generating the edges in this constructor. Defaults to `(src, dst) -> NamedTuple()`;
386+
- `name::Symbol`: The name of the Interlayer. Defaults to Symbol("interlayer_(layer_1.name)_(layer_2.name)");
387+
- `transfer_vertex_metadata::Bool`:if true, vertex metadata found in both connected layers are carried over to the vertices of the Interlayer. NB: not all choice of underlying graph may support this feature. Graphs types that don't support metadata or that pose limitations to it may result in errors.;
388388
"""
389389
empty_interlayer(
390390
layer_1::Layer{T,U},

0 commit comments

Comments
 (0)