robber: Using block model to estimate the robustness of ecological networks. R package

4 Estimated structure of the collection of 3 stream food webs with the four colSBM models. For each network, the matrix on the left is the estimated parameter connectivity α, the barplot on the right depicts π (m) . The ordering is done by trophic level from bottom to top and right to left. For (δ-δπ)colSBM s we give δ below the barplot. . . In abscissa, j is a topology strength parameter. rho is the proportion of column species that belongs to the first column block. • represents a topology with no structure (Erdős-Rényi (ER)). Color gradient varies from blue (less robust than an ER), to white (as robust as an ER), to red (more robust than an ER). The symbols corresponds to the following mesoscale structures:

-large core, strongly connected only to itself, -small core, strongly connected to the whole network, -medium size core strongly connected only to itself, -highly modular with unbalanced blocks' sizes, ♦ -highly modular with slightly smaller highly connected blocks, -highly modular with slightly larger highly connected blocks. . Block Decreasing (resp. increasing) = B ↓ (resp B ↑ ), Ordered Decreasing (resp. Increasing) = D ↓ ord (resp. D ↑ ord ). Linear Decreasing (resp. Increasing) = D ↓ lin (resp. D ↑ lin ). The grey to red gradient stands for (1 -d) nr , the probability to have an empty column under an Erdős-Rényi distribution. The size of the point is the deviation between the biSBM and the empirical robustness in terms of the number of standard deviations of the robustness under a biSBM distribution for S = U. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 170 4.6 Error (RMSE) in the prediction of the robustness of [START_REF] Latouche | Variational bayesian inference and complexity control for stochastic block models[END_REF] Un autre objet d'intérêt est l'évaluation de la résilience d'un système aux perturbations. Dans l'analyse de la robustesse d'un réseau écologique, on cherche à quantifier l'impact que la disparition d'espèces a sur l'écosystème. Par exemple, dans un réseau trophique, où les arêtes sont dirigées et représentent le flux d'énergie apporté par la consommation de ressources, la disparition d'une espèce impacte toute la chaîne trophique. Ce type d'analyse peut également être fait pour des réseaux bipartites tels que des réseaux mutualistes ou antagonistes (un réseau où l'interaction bénéficie à une espèce au détriment de l'autre, tel que le parasitisme ou l'herbivorie). L'analyse de ce phénomène passe par la compréhension du lien entre la structure du réseau et sa robustesse [START_REF] Dunne | Network structure and biodiversity loss in food webs: robustness increases with connectance[END_REF].

Collection de réseaux et réseaux multicouches

Considérer des données provenant de plusieurs réseaux simultanément permet de répondre à de nouvelles questions. Ces réseaux peuvent concerner un même type d'interaction pris dans des contextes différents comme le temps, l'espace, le type des noeuds impliqués, etc. . . Ou bien concerner des réseaux représentant plusieurs types d'interactions mais dont une partie des noeuds est commun. Ceci ne doit pas être confondu avec un grand réseau où l'on aurait regroupé la totalité des noeuds et des interactions de manière indifférenciée. Pour l'analyse, des informations de différentes natures ne doivent pas être mises au même niveau et la signification des différentes interactions doit être préservée pour les différents réseaux d'une collection.

Étudier une collection de réseaux permet par exemple de se demander si des réseaux de relations de conseil impliquant des acteurs différents ont une structure particulière, spécifique à ce type de relations entre acteurs. Une autre application est de comprendre quelles sont les différences structurelles, si elles existent, entre des réseaux mutualistes et antagonistes en écologie (Michalska-Smith and [START_REF] Michalska-Smith | Telling ecological networks apart by their structure: A computational challenge[END_REF].

Lorsque les réseaux d'une collection pourront s'agencer ensemble de manière à créer un système commun via des relations entre les noeuds des différents réseaux, je parlerai de réseaux multicouches. La popularité des réseaux multicouches a explosé récemment comme en témoigne la figure 1.1. En considérant qu'un système n'est pas composé d'un réseau isolé, mais d'une collection de réseaux en interactions. Ils représentent un moyen naturel pour étendre l'analyse des systèmes écologiques [START_REF] Pilosof | The multilayer nature of ecological networks[END_REF] et sociaux [START_REF] Lazega | Multilevel network analysis for the social sciences: Theory, methods and applications[END_REF]. Pour en comprendre l'intérêt, je donne ici, en terme très générique, quelques exemples caractéristiques de différents types de réseaux multicouches. Considérons un réseau de pollinisation et un réseau de parasitisme partageant un même ensemble de plantes, ces deux réseaux peuvent être réunis sous la forme d'un réseau tripartite à deux couches interconnectées par les plantes. Dans ce nouveau réseau l'extinction d'espèce de pollinisateurs a un impact indirect sur les parasites à travers son impact sur les plantes. Les conclusions qualitatives de la robustesse des parasites aux extinctions de cet écosystème diffèrent suivant que l'on considère conjointement plusieurs réseaux sous la forme d'un réseau tripartite ou sous la forme de deux réseaux bipartites [START_REF] Pocock | The robustness and restoration of a network of ecological networks[END_REF][START_REF] Pilosof | The multilayer nature of ecological networks[END_REF]. Introduction (fr)

Cadre des travaux

Avant de présenter un état de l'art, je tiens à préciser trois choses. Bien que justifiées par des applications en écologie ou en sciences sociales, une grande partie des méthodes décrites ci-dessous est applicable à des réseaux issus d'autres domaines (biologie, information. . .). Dans le cadre de cette thèse les réseaux existants dans les applications qui nous intéressent sont de tailles moyennes, de l'ordre de dizaines à quelques centaines de noeuds et sont relativement denses. Ces réseaux sont observés, c'est-à-dire que l'interaction est directement collectée et ne demande pas à être inférée à partir d'autres types de données (données de coocurrences. . .).

État de l'art 1.2.1. Formulation mathématique de réseaux et réseaux multicouches

Un réseau simple (unipartite) est représenté mathématiquement par un graphe G = (V, E), où V est l'ensemble des noeuds (sommets) et E est l'ensemble des arêtes (liens). Dans les réseaux d'interaction qui nous intéressent, un noeud sera par exemple un individu ou une espèce. Les noeuds peuvent être étiquetés par le nom des espèces ou des individus et l'ensemble des labels est alors en bijection avec l'ensemble des n = |V| premiers entiers, où n est le nombre de noeuds du graphe : {labels} {1, . . . , n}.

Une arête est une paire (i, i ) ∈ V × V, à laquelle on peut attribuer une valeur w ii qui représente la force ou la fréquence de l'interaction entre les noeuds i et i . Deux cas nous concernent particulièrement, lorsque l'on s'intéresse simplement à l'existence ou non d'une arête comme dans les réseaux binaires, où alors w ii = 1 pour tout (i, i ) ∈ E et lorsque le nombre d'interactions entre deux noeuds importe, où l'on a alors w ii ∈ N * .

Un réseau simple G = (V, E) peut être représenté par sa matrice d'adjacence A, de taille n × n où pour tout (i, i ) ∈ V 2 :

A ii =   
w ii si les noeuds i et i sont liés avec la valeur w ii 0 sinon.

Introduction

État de l'art 5

Réseaux bipartites Un réseau bipartite est un triplet G B = (V r , V c , E). Dans ce type de réseau, les noeuds sont divisés en deux ensembles disjoints V = V r ∪ V c , V r {1, . . . , n r }, V c {1, . . . , n c } et n r + n c = n, où l'interaction n'est possible qu'entre noeuds de différents ensembles, i.e. D = {(i, j) : i ∈ V r , j ∈ V r }. Ce type de réseau peut-être représenté par sa matrice d'incidence B de taille n r × n c où pour tout (i, j) ∈ V r × V c :

B ij =   
w ij si les noeuds i et j sont liés avec la valeur w ij , 0 sinon.

Dans les réseaux d'interaction qui nous intéressent, soit l'interaction est réciproque (bien qu'elle puisse revêtir une signification différente) soit nous ne sommes concernés que par un seul sens de celle-ci. Par convention, nous posons que les interactions ont lieu de V r vers V c c'est-à-dire des lignes vers les colonnes de B.

Un réseau bipartite peut également être représenté par une matrice d'adjacence (symétrique par bloc) :

A = 0 B B 0 .
Un réseau de pollinisation ainsi que sa matrice d'incidence sont représentés en figure 1.2.

B =          
1 1 1 1 0 0 0 0 0 0 0 1 0 1 0 0 1 0 0 0 1 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 1 0 0 0 1 0 0 0 0

         

Réseaux multicouches

Il existe plusieurs formalismes pour définir des réseaux multicouches [START_REF] Kivelä | Multilayer networks[END_REF]. J'adapterai dans ce qui suit celui de [START_REF] Bianconi | Multilayer Networks: Structure and Function[END_REF]. Un réseau multicouche à M couches est un triplet G = (M, G, B), où M est l'ensemble des couches, M {1, . . . , M }, G = (G 1 , . . . , G M ) est un M -uplet de réseaux unipartites représentant les interactions à l'intérieur d'une même couche :

G m = (V m , E m ) ∀m ∈ M, où V m {1, . . . , n m } et E m ⊂ D m ⊂ V 2 m et B est un M (M -1)
-uplet dont les éléments sont des réseaux bipartites représentant les relations inter-couches :

G B,m,m = (V m , V m , E m,m ) ∀(m = m ) ∈ M 2 .
Comme chaque réseau peut être représenté par sa matrice d'adjacence dans le cas d'un réseau unipartite et sa matrice d'incidence pour un réseau bipartite, dans la plupart des travaux, nous considérerons un réseau multicouche comme une collection de matrices :

X = (A m ) m∈M , (B m,m ) (m =m )∈M 2 ,
qui peut à son tour être aplatie pour définir la matrice de supra-adjacence suivante :

A =       A 1 B 1,2 • • • B 1,M B 1,2 A 2 • • • B 2,M . . . . . . . . . . . . B 1,M B 2,M • • • A M      
.

Parfois dénommés "réseaux liés", "réseaux multipartites généralisés" ou "réseaux de réseaux", il s'agit du type le plus général de réseaux multicouches qui concerne à la fois les interactions inter-couches et intra-couches. En pratique, la plupart des réseaux multicouches n'impliquent qu'un sous-ensemble des réseaux possibles G et B.

Notons que les réseaux unipartites et bipartites sont des réseaux multicouches selon cette définition. En utilisant différentes contraintes, nous pouvons alors définir dans ce cadre certains types de réseaux multicouches d'un intérêt particulier en écologie et en sociologie.

Réseaux multipartites Un réseau multipartite est une généralisation des réseaux bipartites. Les noeuds du réseau sont partitionnés en type et les noeuds n'interagissent pas avec leurs propres types. En d'autres termes, c'est un réseau multicouche sans interaction intra-couche. Souvent appelés réseaux multimodaux dans la littérature sur les réseaux sociaux, les réseaux bipartites -à 2-modes -en sont un cas particulier.

Ainsi un réseau K-partite est défini par G = ({1, . . . , K}, ∅, B), qui peut être représenté par la matrice supra-adjacence suivante :

A =        0 B 1,2 • • • B 1,K B 2,1 0 • • • B 2,K . . . . . . . . . . . . B K,1 B K,2 • • • 0       
.

Généralement, seulement une partie des interactions inter-couches est possible (ou est intéressante) et

|(k = k ) : G B,k,k = ∅| ≤ K(K -1)
. Un exemple typique issu des réseaux écologiques est celui des réseaux tripartites où seulement un ensemble d'espèces est en interaction avec les deux autres, comme les réseaux plantes-pollinisateurs-oiseaux (mutualiste-mutualiste) où les pollinisateurs et les oiseaux n'interagissent qu'avec les plantes ou les réseaux plantes-herbivores-parasites (antagoniste-antagoniste) où les parasites et les plantes ne sont pas en interactions.

Réseaux multiplexes Un réseau multiplexe est un réseau multicouche utilisé pour décrire plusieurs types d'interactions entre un même ensemble de noeuds. En sociologie, des individus peuvent être amis ou échanger des conseils tandis qu'en écologie des espèces peuvent être en compétition pour des ressources tout en coopérant pour d'autres taches.

Dans un réseau multiplexe, les noeuds sont des noeuds répliqués entre les couches et sont justes concernés par les interactions intra-couches :

G = (M, G, ∅), où V m = V m pour tout (m, m ) ∈ M 2 .
La relation entre les noeuds des différentes couches peut être explicitée, donnant le réseau multicouche G = (M, G, B) où les arêtes des réseaux de B sont trivialement celles que relient les noeuds ayant le même label. Cela peut être représenté par la matrice de supra-adjacence suivante :

A =       B 1 I n • • • I n I n B
I n I n • • • B M      
, où I n est la matrice identité de taille n × n.

Notons que dans cette définition les interactions inter-couches sont redondantes et qu'il est possible de se ramener à un réseau simple dont les interactions sont M -dimensionnel de matrice d'adjacence : [START_REF] Abbe | Community detection and the stochastic block model[END_REF], . . . , a ij (M )) ∀(i = j) ∈ V 2 . Introduction (fr)

A ij = (a ij
Réseaux multislices (multicoupes) Un réseau multislice (multicoupe) est utilisé pour représenter des interactions impliquant un même ensemble de noeuds à plusieurs points ordonnés (par exemple le long d'une ligne temporelle ou spatiale). C'est un réseau multicouche où chaque couche représente le réseau d'interaction à un point donné et où les interactions entre les couches identifient les noeuds communs entre points adjacents. C'est donc un réseau multicouche G = (M, G, B) avec les contraintes suivantes :

• V m = V m , ∀(m, m ) ∈ M 2 • E m,m = {(i, i ) ∈ V m × V m : i = i }, ∀(m, m ) ∈ M 2 : m = m + 1
et avec une matrice de supra-adjacence de la forme :

A =              A 1 I n 0 • • • • • • 0 0 A 2 I n 0 • • • 0 . . . . .
0 • • • • • • • • • 0 A M             
.

On peut créer un réseau multislice à partir d'interactions continues dans le temps en segmentant la ligne temporelle en intervalle et en définissant les intersections d'une couche comme celles ayant eu lieu durant un intervalle de temps donné.

Réseaux multiniveaux Les réseaux multiniveaux sont des réseaux multicouches avec une relation hiérarchique entre les couches et où les interactions inter-couches sont possibles uniquement entre couches adjacentes dans la hiérarchie. Dans ce cadre, ils peuvent être vus comme des réseaux multislices sans l'hypothèse de noeuds communs entre les couches et peuvent donc être également utilisés pour représenter des réseaux temporels impliquant des noeuds différents à travers le temps. C'est un réseau multicouche G = (M, G, B) avec les contraintes suivantes :

B = (G B,m,m : m = m + 1 ∀m ∈ {1, . . . , M -1}),
qui peut-être représenté par la matrice d'adjacence :

A =              A 1 B 1,2 0 • • • • • • 0 0 A 2 B 2,3
. . A M -1 B M -1,M 0 • • • • • • • • • 0 A M              .

Quelques modèles probabilistes pour graphes aléatoires

Modèle d'Erdős-Rènyi [START_REF] Erdős | On the evolution of random graphs[END_REF]

P(G) = n 2 m -1
.

À la même époque, [START_REF] Gilbert | Random graphs[END_REF] propose une autre formulation où l'existence de chaque arête est indépendante et identiquement distribuée (i.i.d.) :

P(X ij = 1) = p p ∈ (0, 1), (i, j) ∈ V 2 , i < j.

Le premier modèle est souvent noté par G(n, m) où le nombre d'arêtes est fixé, tandis que le second l'est par G(n, p) où le nombre d'arête est donné en espérance. Par un abus de langage, on nommera par modèle Erdős-Rènyi (ER) n'importe quel modèle de graphe aléatoire où l'existence d'une arête est équiprobable et indépendante des autres arêtes.

Modèles exponentiels de graphes aléatoires (ERGM)

L'ERGM, aussi nommé p * dans la littérature en réseaux sociaux [START_REF] Wasserman | Logit models and logistic regressions for social networks: I. an introduction to markov graphs and p*[END_REF] s'inspire des modèles de régression statistique pour modéliser des graphes aléatoires. L'idée est d'écrire la loi d'un graphe aléatoire comme celle d'une loi de la famille exponentielle :

P θ (X = x) = 1 C(θ)
exp(θ S(x)), où C(θ) = x exp(θ S(x)) est une constante de normalisation et S(x) est un vecteur de statistiques exhaustives du modèle. Par conséquent, tous les graphes ayant la même valeur observée de S ont la même probabilité selon le modèle prédéfini. Ce modèle est largement utilisé dans les sciences sociales, en utilisant S(x) comme un comptage de différents motifs locaux (triangles, k-étoiles, k-triangles. . .) qui revêtent des significations sociologiques [START_REF] Robins | Closure, connectivity and degree distributions: Exponential random graph (p*) models for directed social networks[END_REF]). Cette approche s'étend aux réseaux multicouches : temporels [START_REF] Hanneke | Discrete temporal models of social networks[END_REF], multiniveaux [START_REF] Wang | Exponential random graph models for multilevel networks[END_REF]. . . Les ERGMs s'accompagnent d'importantes limites théoriques et pratiques : le problème de la maximisation de la vraisemblance est mal posé et les modèles sont souvent dégénérés car la distribution se concentre autour d'un mélange de graphes vides et complets [START_REF] Chatterjee | Estimating and understanding exponential random graph models[END_REF]. Introduction (fr)

Modèle Expected Degree Distribution (EDD)

On peut définir un modèle de graphe aléatoire en s'intéressant à la distribution des degrés des noeuds. Dans le modèle EDD [START_REF] Chung | Connected components in random graphs with given expected degree sequences[END_REF], on définit une suite de degrés attendus D = (D 1 , . . . , D n ), et les arêtes du graphe aléatoire G ∈ G(D) sont tirées indépendamment avec une probabilité qui est proportionnelle aux degrés attendus :

p ij = D i D j C ∈ (0, 1) C ∈ R * + ∀(i, j) ∈ V 2 .
De même que le modèle d'Erdős-Rènyi a sa version G(n, m) à nombre d'arêtes fixées, dans le modèle de configuration [START_REF] Bollobás | A probabilistic proof of an asymptotic formula for the number of labelled regular graphs[END_REF], le degré de chaque noeud est fixé. Le graphe est tiré uniformément parmi tous les graphes respectant cette suite de degré (si celle-ci est graphique). Le chapitre 12 du livre de [START_REF] Newman | Networks[END_REF] est consacré à ces deux modèles et à certaines de leurs propriétés.

Modèles à espaces latents pour graphes aléatoires

Les modèles à espaces latents supposent l'existence d'une variable aléatoire latente dont la valeur caractérise la distribution de l'observation. Dans le cas des graphes aléatoires, nous considérerons en général que les variables latentes vont caractériser le comportement des noeuds, apportant de l'hétérogénéité dans les connexions du réseau. Les variables latentes sont notées Z = (Z i , i ∈ V) et permettent d'obtenir un clustering des noeuds du réseau. Les observations X = (X ij ) (i,j)∈D sont indépendantes conditionnellement à ces variables latentes. L'espace des variables latentes peut être continu, par exemple à valeur dans un espace social dont les distances entre individus définissent leur probabilité d'interaction [START_REF] Hoff | Latent space approaches to social network analysis[END_REF][START_REF] Handcock | Model-based clustering for social networks[END_REF]. Le modèle EDD présenté juste au-dessus, peut également être vu comme un modèle à espaces latents où les variables latentes des noeuds seraient les degrés attendus. Dans ce qui suit, je vais m'intéresser aux modèles à espaces latents discrets, en présentant en détail le modèle à blocs stochastiques et certaines de ses extensions. Pour plus de détails sur les modèles à espaces latents pour graphes aléatoires, j'oriente vers la revue relative à ce sujet de [START_REF] Matias | Modeling heterogeneity in random graphs through latent space models: a selective review[END_REF].

Introduction

1.2. État de l'art 11 où π = (π 1 , . . . , π Q ) est le paramètre de mélange. On considèrera également la matrice des appartenances aux blocs Z ∈ {0, 1} n×Q tel que

Z iq =    1 si Z i = q 0 sinon.
Alors, connaissant les blocs d'appartenances, les interactions sont indépendantes de loi :

X ij |Z i , Z j ∼ f (•; α Z i Z j ),
où f est la loi d'émission dépendant du type de valeur de l'arête et α = (α qr ) (q,r)∈Q 2 est la matrice des paramètres de connexion.

En supposant une équivalence stochastique entre les noeuds, la structure modélisée par un SBM est plus universelle que les structures de communautés purement assortatives qui supposent que les probabilités de connexion à l'intérieur d'un bloc sont plus élevées que les probabilités de connexion entre blocs, i.e. α qq > α qr pour tout (q = r) ∈ Q 2 . L'identifiabilité du modèle a été prouvée par [START_REF] Celisse | Consistency of maximumlikelihood and variational estimators in the stochastic block model[END_REF] pour les réseaux binaires.

Le SBM est un outil performant pour la visualisation de graphes, car il résume l'information en quelques paramètres. En effet, la structure méso-échelle d'un réseau peut être décrite par un graphe dont les noeuds représentent les blocs, valués par la cardinalité du bloc, et les arêtes la probabilité ou le nombre attendu d'arêtes entre les blocs. Ce fait est astucieusement utilisé par Peixoto (2014b) pour proposer un SBM imbriqué à différents niveaux de granularité. Les paramètres peuvent également être résumés sous forme matricielle, tel un graphon constant par bloc, modèle que je présente à la fin de la section 1.2.3.

La figure 1.3 illustre les différents types de visualisation possible sur trois topologies classiques de réseaux : communautés assortatives où α qq > α qr pour tout (q = r) ∈ Q 2 , communautés disassortatives où α qq < α qr pour tout (q = r) ∈ Q 2 et coeur-périphérie où un bloc du réseau (le coeur) est fortement connecté au reste du réseau alors que la périphérie est faiblement connectée à elle même.

De nombreuses variantes ont été développées à partir du SBM. Je présente ici celles que j'estime être les plus importantes. Introduction (fr) Ensuite, sachant les blocs latents, les arêtes sont indépendantes de loi :

X ij |Z i , W j ∼ f (•; α Z i W j ).
La version Bernoulli du LBM est identifiable [START_REF] Keribin | Estimation and selection for the latent block model on categorical data[END_REF].

Modèle avec covariables ou annotations

Bien que le SBM soit habituellement utilisé pour les réseaux binaires, il peut être facilement étendu aux arêtes valuées. [START_REF] Mariadassou | Uncovering latent structure in valued graphs: a variational approach[END_REF] montrent cela pour certaines lois d'émissions standards sur les arêtes, mais ils considèrent également un modèle avec des covariables sur les arêtes ajoutant un cadre de régression au SBM. En considérant des réseaux où les arêtes valuées sont modélisées par des variables aléatoires indépendantes de loi de Poisson, ils traitent deux cas, l'un où l'effet des covariables est homogène sur les arêtes :

X ij |Z i , Z j ∼ P ois(α Z i Z j e β Y ij ),
et l'autre où il dépend des blocs (effet inhomogène) :

X ij |Z i , Z j ∼ P ois(α Z i Z j e β ql Y ij ),
où Y ij est le vecteur des covariables β est le paramètre de régression du modèle linéaire généralisé.

Cette approche peut être adaptée aux réseaux binaires en changeant la fonction de lien pour celle d'une régression logistique, on a alors pour le modèle à effet inhomogène :

P(X ij = 1|Z i , Z j ) = 1 1 + e -α Z i Z j -β Y ij . ( 1
X ij |Z i , Z j ∼ P ois(η i α Z i Z j η j ). (1.2)
Le DCSBM est particulièrement utile pour modéliser des structures de communautés assortatives avec une hétérogénéité des degrés à l'intérieur d'une communauté. Ceci a un coût puisque l'on perd l'équivalence stochastique entre les noeuds et en interprétabilité des paramètres du modèle. ∼ q∈Q Bern(π q ). Ainsi, un noeud peut aussi bien appartenir à plusieurs blocs qu'à aucun, ce qui est utile pour modéliser des "outliers". Alors la loi conditionnelle des arêtes sachant les blocs est donnée par :

Modèles avec partition souple

P(X ij = 1|Z i , Z j ) ∼ Bern(Z i Z j + Z i U + Z j V + W * ), où W est une matrice Q × Q modélisant les

Graphon et limite de graphes aléatoires

Le modèle W -graphe représente un modèle de graphe aléatoire échangeable avec le système génératif suivant :

U i ∼ U nif ([0, 1]) ∀ ∈ V X ij = 1|U i , U j ∼ Bern(W (U i , U j )) ∀(i, j) ∈ V 2 .
Il est caractérisé par le graphon, une fonction symétrique mesurable W : [0, 1] 2 → [0, 1]. Les noeuds y possèdent des positions latentes continues qui déterminent leurs probabilités de connexion. Ce modèle définit la limite de la matrice d'adjacence d'un réseau dense [START_REF] Lovász | Limits of dense graph sequences[END_REF]. Le modèle n'est pas identifiable, mais comme montré par [START_REF] Bickel | A nonparametric view of network models and newman-girvan and other modularities[END_REF], ce problème peut être résolu en considérant g : u → 1 0 W (u, v)dv comme une fonction monotone croissante.

On peut relier le SBM à un graphon constant par morceau en considérant

W (u, v) = α C(u)C(v) , C : u → 1 + q∈Q 1 πq≤u .

Extensions du SBM aux réseaux multicouches et à des collections de réseaux

Travailler à partir du SBM permet d'obtenir un cadre très flexible. L'objectif de cette section est de fournir une brève revue sélective de la littérature qui a été développée autour des extensions du SBM et de ses variantes aux réseaux multicouches et aux collections de réseaux. En faisant différentes hypothèses sur la relation entre les blocs latents des différentes couches ou réseaux et sur la façon dont la probabilité des connexions peut varier, une grande variété de modèles a été développée pour les réseaux que nous avons présentés dans la Section 1.2.1. Introduction (fr)

Réseaux multiplexes et collection de réseaux

Les extensions du SBM à des collections de réseaux se concentrent sur des réseaux ayant une correspondance entre les noeuds. Ils ont beaucoup en commun avec les réseaux multiplexes dans leur choix de modélisation, c'est pourquoi je les traite ensemble dans cette section.

On retrouve la volonté de prendre en compte de multiples relations entre les noeuds dès le premier article sur le stochastic block model de Holland et al. (1983). Les relations entre i et j, (i = j) ∈ V

(X ij , X ji ) = (X 1 ij , X 2 ij ) ∈ {0, 1}
P(X ij = k|Z i , Z j ) = α Z i Z j (k), k∈{0,1} M α Z i Z j (k) = 1.
L'hypothèse que les arêtes sont liées peut-être relâchée. On considère alors que chaque arête de chaque couche est générée indépendamment pour chaque m ∈ M (Han et al., 2015; Paul and Chen, 2020) :

X m ij |Z i , Z j ∼ f (•; α m Z i Z j ).
P(X m ij = 1|Z i , Z j ) = logit -1 (α Z i Z j + β m ).
X m ij |m ∈ s, Z s i , Z
O ij = X 1 ij X 2 ij et l'agrégation OR où X O ij = 1 -(1 -X 1 ij )(1 -X 2 ij ) pour tout (i = j) ∈ V
(X m ij = 1|X ij , Z i , Z j ) = X ij P Z i Z j + (1 - X ij )(1 -Q Z i Z j ).
D'autres auteurs s'intéressent à la variabilité des appartenances aux blocs entre les réseaux. Paul and Chen (2018) autorisent les noeuds à changer de blocs entre les réseaux. Pour cela, ils définissent Z ∈ [0, 1] n×Q comme étant la moyenne des appartenances de chacun des n noeuds, dans un des Q blocs à travers les M réseaux, puis définissent une matrice de transition T de taille Q × Q, tel que

Z m i ∼ M ult(1, Zi T ), i ∈ V, m ∈ M.
La loi de X m |Z m suit alors celle d'un SBM de paramètre de connexion α m , avec pour des raisons d'identifiabilité la contrainte que le vecteur des connexions intra-blocs (α m 11 , . . . , α m QQ ) soit le même pour tout m ∈ M. Sweet et al. (2014) considèrent un mixed membership SBM (MMSBM) qui, par différentes configurations de hiérarchie de lois a priori sur les paramètres de modèles, permet de modéliser des structures de dépendances complexes entre les réseaux. intra-blocs où pour des raisons d'identifiabilité des blocs à travers le temps α t qq = α t qq pour tout q ∈ Q, (t, t ) ∈ {1, . . . , T } 2 ). Cette idée a été récemment étendue pour prendre en compte la réciprocité en modélisant un couple d'arête à valeur dans {(0, 0), (0, 1), (1, 0), (1, 1)} par [START_REF] Bartolucci | Dealing with reciprocity in dynamic stochastic block models[END_REF].

Réseaux temporels et spatiaux

Enfin, bien que cela ne porte pas à proprement parler sur un réseau multicouche,

P(Z k i = q) = π k q q ∈ {1, . . . , Q k }, i ∈ V k , et pour tout pour (k, k ) ∈ {1, . . . , K} 2 , X kk ij |Z k i , Z k j ∼ f k,k (•; α kk Z k i Z k j ), (i, j) ∈ D k,k .

Techniques d'inférence et algorithmes

Méthodes variationnelles

Dans une approche par maximum de vraisemblance, l'objectif est de maximiser la vraisemblance des données observées. Pour faire cela, une idée naturelle serait d'intégrer sur les variables latentes la vraisemblance complète : [START_REF] Lauritzen | Graphical models[END_REF], on peut montrer que la loi de Z|X ne peut pas être factorisée comme illustrée par la moralisation du graphe dirigé acyclique (DAG) de la figure 1.4. Ainsi, l'algorithme EM ne peut pas être appliqué à notre cas, mais l'on peut se rabattre sur une approximation variationnelle [START_REF] Jordan | An introduction to variational methods for graphical models[END_REF]. Dans l'EM variationnel (VEM), nous voulons maximiser la borne variationnelle qui est une borne inférieure de la log-vraisemblance des données observées :

L θ (X) = z∈Z L θ (X, Z = z),
θ (X) := log L θ (X) ≥ J (R, θ) := θ (X) -KL(R||P θ (•|X)) (1.3) = E R [ θ (X, Z)] + H(R), (1.4) Introduction (fr)
et H est l'entropie de Shannon :

H(R) = -E R [log R(Z)] = - z R(z) log R(z),
et R est une distribution sur les variables latentes Z. Dans le cas du SBM, la complexité computationelle vient de l'absence de factorisation de la loi de Z|X. Le VEM repose alors sur une approximation à champ moyen de manière à ce que R soit choisi dans une famille de distribution entièrement factorisable de la forme :

R(Z) = i∈V R i (Z i ) = i∈V q∈Q τ Z iq iq , où τ iq = E R [Z iq ]
, avec la contrainte que q∈Q τ iq = 1 pour tout i ∈ V. τ := {(τ i1 , . . . , τ iQ )} i∈V sont appelés les paramètres variationnels.

Le VEM consiste alors à itérer les deux étapes suivantes :

V E-step On calcule τ (t+1) = arg max τ J (R, θ (t) ),
cela revient à maximiser l'équation (1.3) et ainsi à minimiser la divergence de Kullback-Leibler, c'est à dire à trouver la loi variationnelle des affectations aux blocs la plus proche de Z|X pour les paramètres courants θ (t) .

M -step On calcule θ (t+1) = arg max θ J (R (t) , θ),
ce qui revient à maximiser l'équation (1.4).

Pour l'implémentation de l'algorithme VEM dans le cas du SBM standard [START_REF] Daudin | A mixture model for random graphs[END_REF], l'étape V E repose sur un algorithme de point fixe. Il n'y a pas de garantie de l'unicité de ce point fixe et donc que l'étape V E va accroître la borne variationnelle en pratique. Toutefois, cela fonctionne très bien empiriquement. Vu et al. (2012) remplacent la maximisation de l'étape V E par une étape dite de "Generalized" E-step qui se contente d'augmenter la borne variationnelle. Pour l'étape M , il existe une forme close et les estimateurs des paramètres sont facilement interprétables :

πq = 1 n i∈V τ iq αqr = (i =j)∈V 2 τ iq τ jr X ij (i =j)∈V 2 τ iq τ jr
, il s'agit respectivement de la proportion moyenne de noeuds dans le bloc q et la fréquence moyenne des arêtes entre les blocs q et r. en supposant l'indépendance des paramètres de mélange et de connexion. Le terme dépendant de π est calculé en choisissant une loi a priori adaptée (une loi de Dirichlet qui est conjuguée pour une loi multinomiale), dont on peut faire un développement asymptotique avec la formule de Stirling, tandis que le terme en α l'est par une approximation asymptotique de type BIC [START_REF] Schwarz | Estimating the dimension of a model[END_REF] :

ICL(X, Q) = max θ θ (X, Ẑ|Q) -pen(Q).
pen(Q) = 1 2 (Q -1) log(n) + Q(Q + 1) 2 log(|D|
β(Q) = θ∈Θ Q log L θ (X) -λ Q(Q + 1) 2 n log n,
où λ est un paramètre de régularisation. La consistance du critère est conservée même si la vraisemblance des données observées peut-être remplacée par sa borne variationnelle J en utilisant un résultat de convergence de la borne variationnelle [START_REF] Bickel | Asymptotic normality of maximum likelihood and its variational approximation for stochastic blockmodels[END_REF] [START_REF] Schwarz | Estimating the dimension of a model[END_REF]. L'approche de sélection de modèle par classification, peut être reliée à celle par densité grâce à la relation suivante :

(X|Q) = (X, Z|Q) -(Z|X, Q),
que l'on applique à l'expression du BIC.

BIC(Q) = max θ θ (X) -pen BIC (Q) = max θ E P θ (Z|X) [ θ (X, Z|Q) -θ (Z|X, Q)] -pen BIC (Q) = max θ E P θ (Z|X) [ θ (X, Z|Q)] + H(P θ (•|X)|Q) -pen BIC (Q).
Si l'on conjecture que pen BIC (Q) = pen ICL (Q), on peut alors voir l'ICL comme le BIC pénalisé par un terme d'entropie. Ce terme est maximal lorsque

P θ (Z i = q|X) = 1 Q ∀q ∈ Q
et a contrario tend vers 0 lorsque toute la masse se concentre en un seul point, ce qui est le cas asymptotiquement pour le SBM [START_REF] Mariadassou | Convergence of the groups posterior distribution in latent or stochastic block models[END_REF]. Donc l'ICL pénalise d'avantage que le BIC les clusters mal séparés, mais sous cette conjecture, les 2 critères sont équivalents asymptotiquement.

Dans notre cas, nous ne connaissons pas la loi de Z|X et nous avons recours à une approximation variationnelle, alors :

max θ θ (X) = max θ E R[ θ (X, Z|Q)] + H( R|Q) J ( R,θ|Q) -H( R|Q) + E R[ θ (Z|X, Q)] KL( R P θ (•|X)|Q)
, et sous la même conjecture sur les pénalités que précédemment, on peut obtenir une approximation du BIC à partir du calcul de l'ICL :

BIC(Q) = ICL(Q) + H( R|Q) + KL( R P θ (•|X)|Q) ≥ max
des clusterings R qr = i∈V 1 C i =q,D i =r pour tout (q, r) ∈ Q 2 et R +r = q∈Q R qr (resp. R q+ = r∈Q R qr ).
Alors on peut réécrire le NMI comme suit :

NMI(C, D) = 2( q∈Q (R q+ log R q+ n + R +q log R +q n -r∈Q Rqr n log Rqr n 2 )) q∈Q (R q+ log R q+ n + R +q log R +q n )
.

Le
a 11 = (i =j)∈D 1 C i =C j ,D i =D j , a 01 = (i =j)∈D 1 C i =C j ,D i =D j , a 10 = (i =j)∈D 1 C i =C j ,D i =D j , a 00 = (i =j)∈D 1 C i =C j ,D i =D j .
Le Rand Index (RI) est défini par RI(C, D) = a 11 +a 00 ( n 2 )

. Cet indice reste défini même si le nombre de blocs est différent entre les 2 clusterings et permet ainsi de comparer des clusterings obtenus à partir de modèles de tailles différentes. Il est possible de faire le lien entre les termes (a kl ) (k,l)∈{0,1} 2 et la table de contingence R qr = i∈V 1 C i =q,D i =r , (q, r) ∈ Q C × Q D , en particulier :

a 11 = (q,r)∈Q C ×Q D R qr 2 , a 00 = n 2 + (q,r)∈Q C ×Q D R qr 2 - q∈Q C R q+ 2 - r∈Q D R +r 2 .
L'ARI corrige le RI en supposant que la table de contingence construite suit une loi hypergéométrique :

ARI(C, D) = RI(C, D) -E[RI(C, D)] 1 -E[RI(C, D)] , (1.7) où E[RI(C, D)] = 1 + 2 q∈Q C ( R q+ 2 ) r∈Q D ( R +r 2 ) ( n 2 ) 2 -q∈Q C ( R q+ 2 )+ r∈Q D ( R +r 2 ) ( n 2 )
.

pij = P(X ij = 1|D O ) = (q,r)∈ Q2
Ẑiq α qr Ẑjr , (1.9) Introduction (fr)

Utilisation des données manquantes et bruitées

Les réseaux bruités et/ou partiellement observés peuvent également être utilisés à travers des simulations comme outil de sélection de modèles, de vérification d'algorithmes ou même pour quantifier les différences entre les réseaux dans une collection de réseaux. Je donne ici quelques exemples d'utilisation ainsi que les outils dont je me servirai dans cette thèse.

Sélection de modèle

Comme indiqué en section 1.2.6, Chen and Lei (2018) proposent, pour choisir le nombre de blocs dans un SBM et pour choisir entre SBM et un DCSBM, une méthode de validation croisée par bloc. L'ensemble des noeuds V est divisé en une partition aléatoire (V 1 , V 2 ), l'objectif est de minimiser une erreur de prédiction sur les arêtes (i = j) ∈ V 2 2 qui sont manquantes. L'avantage de cette approche est qu'elle peut se généraliser facilement à n'importe quelle extension du SBM, mais au prix d'un fort coût algorithmique.

Quantifier la dépendance entre réseaux

On peut utiliser la prédiction de dyades manquantes pour le réseau. L'idée est de dire que deux couches de réseau sont interdépendantes si et seulement si l'information contenue dans l'une des couches permet d'améliorer la prédiction des arêtes de l'autre couche. C'est ce que font De Bacco et al. (2017), dans le cadre d'un MMSBM pour réseau multiplexe, en masquant une partie d'une couche et en comparant la prédiction des dyades manquantes entre un MMSBM sur cette unique couche et un MMSBM sur toutes les couches du réseaux multiplexe. Ils utilisent l'aire sous la courbe ROC (ROC AUC) pour comparer les prédictions, indices que je définis ci-dessous.

ROC AUC Pour juger de la performance de la prédiction on utilise le ROC AUC. Soit X T la représentation matricielle du vrai réseau, X O le réseau observé et D U l'ensemble des dyades/arêtes à prédire. Soit R ij le rang de p ij pour tout (i, j) ∈ D U par ordre décroissant. Définissons alors les taux de vrais positifs (TPR) et de faux positifs (FPR) en fonction d'un seuil k ∈]0, 1] :

T P R(k) = |(i, j) ∈ D U : R ij ≤ k|D U |, X T ij = 1| |(i, j) ∈ D U : X T ij = 1| , F P R(k) = |(i, j) ∈ D U : R ij ≤ k|D U |, X T ij = 0| |(i, j) ∈ D U : X T ij = 0|
.

On définit alors ROC AUC := 1 0 T P R(F P R -1 (k))dk. Le ROC AUC prend des valeurs entre 0 et 1, et la prédiction est d'autant meilleure que cette valeur est grande.

Une méthode qui place la même probabilité sur chaque arête a un ROC AUC de 1 2 . La définition du ROC AUC est directement applicable aux données bruitées via la prédiction d'arêtes manquantes ou fallacieuses.

Stabilité du clustering

Simuler des données manquantes permet également d'évaluer la pertinence d'une modélisation jointe d'une collection en regardant si celle-ci améliore la stabilité du clustering (Žnidaršič et al., 2012). Pour cela, on utilise une méthode de comparaison de clustering (par ex. : l'ARI défini en section 1.2.7) afin de comparer le clustering obtenu à partir du réseau où l'information est complète et celui obtenu à partir du réseau avec des données manquantes. Plus formellement, soit X T le vrai réseau et X O le réseau observé. Soit C une fonction de clustering, notre indice de stabilité est alors donné par ARI(C(V|X T ), C(V|X O )). Alors, dans le cadre d'une collection de réseau X, les réseaux m et m sont liés si l'un permet de stabiliser le clustering de l'autre, i.e.

ARI(C(V

m |X m,T , X m ), C(V m |X m,O , X m )) > ARI(C(V m |X m,T ), C(V m |X m,O )).

Contributions de la thèse

Les contributions de cette thèse sont réparties en trois travaux. Deux ont trait à la modélisation conjointe de réseaux n'ayant pas de noeuds communs à travers des extensions du SBM. Dans le chapitre 2, nous nous intéressons à la modélisation de réseaux multiniveaux. Nous introduisons une dépendance entre les noeuds de ces niveaux, sous la forme d'une dépendance entre les blocs latents, et tentons de comprendre l'influence d'un niveau sur la structure de connexion de l'autre niveau ; la structure de chaque niveau est laissée libre. Nous considérons un autre type de dépendance dans le chapitre 3, où nous modélisons une collection de réseaux et tentons de retrouver une structure de connexion communes aux différents réseaux. La dépendance entre les réseaux est introduite par l'hypothèse qu'ils partagent une structure commune ce qui se traduit par une correspondance entre les blocs latents. Enfin dans un dernier travail, présenté au chapitre 4, nous utilisons des modèles paramétriques adaptés à des réseaux bipartites et en particulier le SBM pour dériver une expression exacte sous ce modèle d'un indice communément utilisé en écologie pour quantifier la résilience d'un écosystème face à la disparition d'espèce, appelé la robustesse. Cette nouvelle expression de la robustesse permet entre autres via la renormalisation des paramètres du SBM de comparer la robustesse d'une collection de réseaux. Ces trois travaux comportent des librairies complètement documentées pour le logiciel R permettant d'appliquer facilement ces méthodes à de nouveaux jeux de données. Je résume les contributions majeures des différents chapitres ci-dessous, les notations sont celles de l'article et peuvent différer de celles définies dans le début de cette introduction. Introduction (fr)

P(X O jj = 1|Z O j , Z O j ) = α O Z O j Z O j P(X I ii = 1|Z I i , Z I i ) = α I Z I i Z I i .
Par conséquent, les blocs regroupent des noeuds partageant le même profil de connectivité. Afin de prendre en compte le fait que les organisations puissent structurer les comportements indivuels, nous supposons que l'appartenance au bloc des individus (Z I ) dépend du bloc des organisations (Z O ) auxquels ils sont affiliés. Plus précisément, nous posons :

P(Z I i = k|Z O j , A ij = 1) = γ kZ O j ∀i ∈ {1, . . . , n I } ∀k ∈ {1, . . . , Q I } où γ est une matrice de taille Q I ×Q O tel que Q I k=1 γ kl = 1 pour tout l ∈ {1, . . . , Q O }. Les (Z O j )
sont des variables aléatoires i.i.d. :

P(Z O j = l) = π O l , ∀j ∈ {1, . . . , n O } ∀l ∈ {1, . . . , Q O } tel que Q O l=1 π O l = 1.
Un petit réseau multiniveau est décrit dans la Figure 1

α O •• α O •• α O •• 1 2 3 4 5 6 7 α I •• α I •• α I •• α I •• Figure 1.5 -
{Q I ,Q O } ICL MLVSBM (Q I , Q O ) ≤ max Q I ICL I SBM (Q I ) + max Q O ICL O SBM (Q O ). Introduction (fr)
matrices d'adjacences X = {X 1 , . . . , X M }, par M SBMs indépendants (separated SBM) de paramètres spécifiques à chaque réseau :

X ∼ M m=1 SBM nm (Q m , π m , α m ). (sepSBM )
Pour retrouver une structure commune, nous allons contraindre certains paramètres du SBM à être les mêmes d'un réseau à l'autre. Le modèle le plus contraint, appelé iid-colSBM suppose que chaque noeud de la collection a la même probabilité d'appartenir à chacun des blocs, et que les paramètres de la loi d'émission conditionnelle sont les mêmes :

X ∼ M m=1 SBM nm (Q, π, α). (iid-colSBM )
Nous introduisons deux mécanismes pour relâcher ces contraintes, le premier est d'autoriser les proportions de blocs à varier suivant les réseaux et de permettre aux blocs de n'être représentés que dans un sous-ensemble des réseaux. Cela permet de modéliser des structures imbriquées entre réseaux ou des structures qui se recoupent partiellement :

X ∼ M m=1 SBM nm (Q, π m , α), (π-colSBM )
q∈Q π m q = 1 avec π q ≥ 0. Le second mécanisme est d'autoriser la densité du réseau à varier tout en gardant les mêmes rapports relatifs de connexions entre blocs, pour cela nous introduisons un paramètre de densité spécifique à chaque réseau δ m :

X ∼ M m=1 SBM nm (Q, π, δ m α).
(δ-colSBM )

Enfin, nous proposons un dernier modèle regroupant les deux mécanismes :

X ∼ M m=1 SBM nm (Q, π m , δ m α), (δπ-colSBM )
q∈Q π m q = 1 avec π q ≥ 0. Chaque modèle repose sur un support que nous représentons sous la forme d'une matrice S ∈ {0, 1} M ×Q indiquant les blocs autorisés pour chaque réseau :

S mq = 1 π m q >0 , ∀q = {1, . . . Q}, m = {1, . . . , M }.
Nous dérivons des conditions d'identifiabilité pour chacun des quatre colSBM s, celle du sepSBM étant immédiate. Nous proposons un algorithme variationnel pour l'inférence des paramètres du modèle et des clusterings. Pour la sélection du support, nous proposons une approximation du BIC via un critère ICL. Ce critère a de nombreuses autres utilités. Il permet de choisir entre les cinq modèles introduits ci-dessus, avec pour conséquence de donner une règle de décision pour juger de la pertinence de la structure commune. Cela permet également de proposer une partition des réseaux en regroupant ceux ayant une structure similaire.

R S (A) = 1 n r nr m=0 R S (A, m) = 1 n r nr m=0 E S [R(A, S, m)] with S ∼ S , où R(A, S, m) = 1 - 1 n c nc j=1 1 { nr i=m+1 A S(i)j =0}
est la proportion de noeuds en colonne restant connectés après m extinctions. Cette espérance, comme fonction de m, s'appelle la fonction de robustesse et est généralement approchée par une intégration Monte Carlo sur S.

Afin de relier la structure du réseau à sa robustesse, nous proposons de mettre une loi A sur A et d'intégrer la robustesse sur le couple (A, S) ∼ (A, S). Si la loi du réseau est paramétrique, et que ces paramètres expliquent en partie la structure du réseau, nous pouvons alors relier la structure du réseau à sa robustesse.

Nous dérivons les premiers moments de la fonction de robustesse lorsque S = U est une loi uniforme sur les permutations du groupe symétrique S nr , indépendante de la loi du réseau, pour A qui suit un SBM bipartite (biSBM ) de paramètres θ = (π, ρ, δ), où δ est le paramètre de connectivité. En particulier, nous obtenons une expression analytique de l'espérance :

E (A,S) [R(A, S, m)] = 1 - Qc q=1 ρ q (1 -δ +q ) nr-m , où δ +q = Qr k=1 π k δ kq , et de la variance V A (E S|A [R(A, S, m)|A]
). Afin d'obtenir des scénarios d'extinctions plus réalistes et de s'intéresser à des cas plus ou moins favorables à la robustesse de l'écosystème, nous obtenons également une expression de l'espérance de la robustesse suivant une loi des séquences d'extinctions primaires dépendantes des blocs du biSBM . Dans ce cas, la loi du couple (A, S) ∼ (A, B) n'est pas factorisable :

R θ,n,B (m) = 1 - Qc q=1 ρ q n 1 +•••+n Qr =nr n r ! n 1 ! . . . n Qr ! Qr k=1 π n k k (1 -δ kq ) Introduction (fr)
Nous dérivons également des propriétés en terme de borne supérieure pour la robustesse ainsi que de monotonie par rapport au nombre de noeuds, du nombre d'extinctions et des paramètres. En particulier, à nombre de noeuds et densité d = (k,q)∈(Qr×Qc) π k ρ q δ kq fixés, l'ensemble des paramètres qui majorent l'espérance de la robustesse d'un biSBM pour S = U comprend ceux d'un Erdős-Rényi (de robustesse

E (A,S) [R(A, S, m)] = 1 -(1 -d) nr-m
). Et parmi cet ensemble, c'est le paramètre de l'Erdős-Rényi qui minimise la variance de la robustesse.

Package R

Les développements méthodologiques de la thèse ont été implémentés dans 3 packages. This model contains latent blocks accounting for heterogeneity in the patterns of connection within each level and introducing dependencies between the levels. The sought connection patterns are not specified a priori which makes this approach flexible. Variational methods are used for the model inference and an Integrated Classified Likelihood criterion is developed for choosing the number of blocks and also for deciding whether the two levels are dependent or not. A comprehensive simulation study exhibits the benefit of considering this approach, illustrates the robustness of the clustering and highlights the reliability of the criterion used for model selection. This approach is applied on a sociological dataset collected during a television program trade fair, the inter-organizational level being the economic network between companies and the inter-individual level being the informal network between their representatives. It brings a synthetic representation of the two networks unraveling their intertwined structure and confirms the coopetition at stake.

Introduction

The statistical analysis of network data has been a hot topic for the last decade. The last few years witnessed a growing interest for multilayer networks (see [START_REF] Kivelä | Multilayer networks[END_REF][START_REF] Bianconi | Multilayer Networks: Structure and Function[END_REF][START_REF] Giordano | Analyzing multiplex networks using factorial methods[END_REF]. A particular case of multilayer networks are multilevel networks where each level is a layer and an affiliation relationship represents the inter-layer. Multilevel networks are used across many fields such as sociology [START_REF] Lazega | Multilevel network analysis for the social sciences: Theory, methods and applications[END_REF] or environmental science [START_REF] Hileman | The network structure of multilevel water resources governance in central america[END_REF]. In particular they arise in the sociology of organizations and collective action when willing to study jointly the social network of individuals and the interaction network of organizations the individuals belong to. Indeed, the individuals not only interact with each others but are also members of interacting organizations. This approach is quite generic in the social sciences and all the phenomena of coopetition and the maintenance of social inequalities can fall within the scope of this approach (Lazega and Jourda, 2016). It is also gaining attention as a way to articulate social network analysis and the life course studies [START_REF] Vacchiano | What multilevel networks reveal about the life course: Insights on cumulative (dis)advantages[END_REF]. Following [START_REF] Lazega | Multilevel network analysis for the social sciences: Theory, methods and applications[END_REF], one might think that these two types of interactions (between individuals and between organizations) are interdependent, the individuals shaping their organizations and the organizations having an influence on the individuals. We aim to propose a statistical model for multilevel networks in order to understand how the two levels are intertwined and how one level impacts the other.

In what follows, a multilevel network is defined as the collection of an inter-individual network, an inter-organizational network and the affiliation of the individuals to ) that they can both fit to a wide range of topologies since they gather into blocks the nodes that are structurally equivalent. However, contrary to the generalized blockmodeling which seeks a pre-specified structure in the network with given ideal blocks, the SBM is agnostic and is aimed to unravel any kind of block structure which may shape the data. This includes but is not restricted to the detection of assortative communities where the probability of connection within a block is higher than the probability of connection between the blocks. Moreover, the probabilistic generative model allows the modeler to have a unified framework for model selection and natural extensions such as dealing with non binary dyads and link prediction. The SBMs have been extended to particular types of multilayer networks : [START_REF] Barbillon | Stochastic block models for multiplex networks: an application to a multilevel network of researchers[END_REF] propose an SBM for multiplex networks and Matias and Miele (2017) an SBM for time-evolving networks. In this paper, we propose an SBM suited to multilevel networks (MLVSBM).

Our contribution In a few words, we model the heterogeneity in the interindividual and inter-organizational connections by introducing blocks of individuals and blocks of organizations, the blocks containing homogeneous groups of actors (individuals or organizations) with respect to their connectivity. The two levels are assumed to be interdependent through their latent blocks. More specifically, the latent blocks of the inter-individual level depend on the latent blocks of the inter-organizational level and the affiliation. This bi-clustering approach allows us to determine how groups of organizations influence the connectivity patterns of their individuals. Note that the hierarchical model does not assume a causal effect of the blocks of organizations on the blocks of individuals but an interdependence between the two sets of blocks.

Due to the latent variables, the estimation of the parameters is a complex task. We resort to a variational version of the Expectation-Maximization (EM) algorithm.

For the SBM, the variational approach ( ). In the latent block model which is suited for bipartite network, the variational estimates have also been successfully applied [START_REF] Govaert | Block clustering with bernoulli mixture models: Comparison of different approaches[END_REF]. In this paper, we obtain approximate maximum likelihood estimates by an ad-hoc version of the variational EM algorithm.

Another important task is the choice of the number of blocks. We propose an adapted version of the Integrated Complete Likelihood (ICL) criterion. First developed by [START_REF] Biernacki | Assessing a mixture model for clustering with the integrated completed likelihood[END_REF] for mixture models as an alternative to the Bayesian Information Criterion (BIC), it was then adapted by [START_REF] Daudin | A mixture model for random graphs[END_REF] to the SBM. The ICL has since illustrated its efficiency and relevance for various SBMs and their extensions such as multiplex network [START_REF] Barbillon | Stochastic block models for multiplex networks: an application to a multilevel network of researchers[END_REF], dynamic SBM (Matias and Miele, 2017) or degree corrected SBM [START_REF] Yan | Bayesian model selection of stochastic block models[END_REF]. A further reference for dynamic SBMs is [START_REF] Bartolucci | Dealing with reciprocity in dynamic stochastic block models[END_REF]. Besides, a critical issue in sociology is to verify the multilevel interdependence hypothesis in a multilevel network, i.e. if the two levels (inter-individual and inter-organizational) should be analyzed jointly or if a separate analysis is sufficient. We thus propose a criterion to decide whether the two levels are independent or not.

Related works

The term multilevel network arises in the statistical literature for a wide variety of complex networks. . When focusing on a clustering approach, Žiberna (2014) develops three general approaches for blockmodeling multilevel networks. First, the separate analysis consists in clustering the levels separately or using the clustering of one level on the other. Second, the conversion approach converts the level of the organizations into a new kind of interaction between individuals, the interactions are then aggregated into a single layer network; this is close to the approach taken by Barbillon et al. ( 2017) who transform the inter-organizational network into an inter-individual network thus adopting a multiplex network approach (the individuals interconnect directly or through the organizations they belong to). The third approach is called the true multilevel approach and is the closest to the one we propose on this paper.

Žiberna (2014) and the extensions in Žiberna (2019, 2020) to a more general set of multilayer networks (called linked networks) use a generalized blockmodeling framework [START_REF] Doreian | Generalized blockmodeling[END_REF]. Contrary to this deterministic approach, we resort to a probabilistic generative model for all the reasons stated above. The MLVSBM additionally provides us with a natural criterion for detecting the interdependence between the two levels. Furthermore, we explicitly take into account the constraint of having a unique affiliation per individual inherent to these multilevel datasets A Stochastic Block Model for the Analysis of Multilevel Networks and do not consider the affiliation as a bipartite network.

Also, note that the multiplex SBM approach applied to a multilevel network suggested by [START_REF] Barbillon | Stochastic block models for multiplex networks: an application to a multilevel network of researchers[END_REF] is only applicable when the numbers of individuals and organizations are close. Indeed it requires to duplicate the data of the interorganizational level to fit the size of the inter-individual level. Furthermore, it only provides a clustering of the individuals and not two clusterings, one of the individuals and one of the organizations. In contrast, our MLVSBM does not need to transform the data into a multiplex network and is able to obtain a clustering of the nodes within each level.

If we release the constraint of the unique affiliation, then the inter-level can be modeled by a latent block model and we obtain a particular case of the multipartite SBM of Bar-Hen et al. (2020). However, the interactions between individuals and organizations are considered at the same level as the affiliations, and the clustering might be strongly influenced by the number of individuals in each organization.

Finally, our work is also different from the SBM with edges covariates [START_REF] Mariadassou | Uncovering latent structure in valued graphs: a variational approach[END_REF] with the individuals as nodes and the inter-organizational network as edges covariates. Indeed, in that case, the clustering obtained for the individuals is the remaining structure of the inter-individual level once the effect of the covariates has been taken into account. In addition, this model does not provide a clustering of the organizations.

Outline of the paper

The paper is organized as follows. The SBM adapted to multilevel networks (MLVSBM) is defined in Section 2.2. We also give conditions guaranteeing the independence between levels and the identifiability of the parameters. The inference strategy and the model selection criterion are provided in Section 2.3. The proof of the independence between levels, of the identifiability and the details on the variational EM and the ICL criterion are postponed to the Appendix sections. In Section 2.4, we present an extensive simulation study illustrating the relevance of our inference method, model selection criterion and procedure. Section 2.5 is dedicated to the analysis of a sociological dataset by our MLVSBM. Finally we discuss our contribution and future works in Section 2.6.

A multilevel stochastic block model

Dataset Let us consider n I individuals involved in n O organizations. We encode the networks into adjacency matrices as follows. Let X I be the binary n I × n I matrix representing the inter-individual network. X I is such that : ∀(i, i ) ∈ {1, . . . , n I } 2 :

X I ii =    1 if there is an interaction from individual i to individual i , 0 otherwise. (2.1) X O is the binary n O × n O matrix representing the inter-organizational network, ∀(j, j ) ∈ {1, . . . , n O } 2 : X O jj =   
1 if there is an interaction from organization j to organization j , 0 otherwise.

(2.2) Remark. In general, no self-loop are considered in the network, thus the interactions are defined for i = i and j = j . Moreover, if the interactions are undirected then

X I ii = X I i i ∀(i, i ) or/and X O jj = X O j j ∀(j, j ).
In what follows, we present the methodology for undirected networks. However, all the results can be adapted to directed networks without any difficulty.

Let A be the affiliation matrix. A is a n I × n O matrix such that:

A ij =    1 if individual i belongs to organization j, 0 otherwise . A is such that ∀i = 1, . . . , n I , n O j=1 A ij = 1
since we assume that any individual belongs to a unique organization. A synthetic view of a generic dataset is provided in Figure 2.1.

n I n O Individual 1 0 1 0 010 0 . . . X I ii A ij Individual n I 1 0 0 - 01 Organization 1 0 1 . . . X O jj Organization n O 1 0 Individual 1 • • • Individual n I Organization 1 • • • Organization n O
I i = k if individual i belongs to block k (k ∈ {1, . . . , Q I }).
Given these clusterings, we assume that the interactions between organizations and the interactions between individuals are independent and distributed as follows:

P(X O jj = 1|Z O j , Z O j ) = α O Z O j Z O j , P(X I ii = 1|Z I i , Z I i ) = α I Z I i Z I i . (2.3)
As a consequence, the blocks gather nodes (blocks of individuals on the one hand and blocks of organizations on the other hand) sharing the same profiles of connectivity.

In order to take into account the fact that organizations may shape the individual behaviors, we assume that the memberships of the individuals (Z I ) depend on the blocks of the organizations (Z O ) they are affiliated to. More precisely, we set:

P(Z I i = k|Z O j , A ij = 1) = γ kZ O j ∀i ∈ {1, . . . , n I } ∀k ∈ {1, . . . , Q I }, (2.4)
where γ is a

Q I × Q O matrix such that Q I k=1 γ kl = 1 ∀l ∈ {1, . . . , Q O }. The (Z O j
) are assumed to be independent random variables distributed as

P(Z O j = l) = π O l , ∀j ∈ {1, . . . , n O } ∀l ∈ {1, . . . , Q O }, (2.5)
with

Q O l=1 π O l = 1. Equations (2.4
) and (2.5) state that the clustering of an individual is not completely driven by his/her behavior but is also shaped by the clustering of the organization he/she belongs to. In particular, if Q O = Q I and γ is equal to the identity matrix (up to a reordering of the rows) then, the clustering of the individuals is completely determined by the clustering of the organizations. At the opposite, if all the columns of γ are equal, then the clustering of the individuals is independent on the clustering of the organizations. This point will be developed hereafter. Likelihood From Equations (2.3), (2.4) and (2.5), we derive the complete loglikelihood for an undirected MLVSBM: The log-likelihood of the observations θ (X|A) is obtained by integrating out the latent variables Z in Equation 2.6. As soon as n O , n I , Q O , or Q I increase, this summation over all the possible clusterings Z I and Z O cannot be performed within a reasonable computational time. As a consequence, we will resort to the variational EM algorithm to maximize this likelihood (see Section 2.3).

log θ X I , X O , Z|A = log π O (Z O ) + log γ (Z I |Z O , A) + log α I (X I |Z I ) + log α O (X O |Z O ) = j,l 1 Z O j =l log π O l + i,k 1 Z I i =k j,l A ij 1 Z O j =l log γ kl (2.6) + 1 2 i =i k,k 1 Z I i =k 1 Z I i =k log φ(X I ii , α I kk ) + 1 2 j =j l,l 1 Z O j =l 1 Z O j =l log φ(X O jj , α O ll ), where φ(x, a) = a x (1 -a) 1-x . A Z O Z I X I X O
Independence We now derive conditions for the structural independence between levels in terms of parameters equality. Proposition 2.1. In the MLVSBM, the two following properties are equivalent:

1. Z I is independent on Z O , 2. γ kl = γ kl ∀l, l ∈ {1, . . . , Q O },
and imply that:

3. X I and X O are independent.

This proposition is proved in 2.A. Proposition 2.1 can be interpreted as follows: in the case where the clustering of the individuals does not depend on the clustering of the organizations, all column vectors of γ are identical. Hence, under this restriction on γ, the model for multilevel network can be rewritten as the product of two independent SBMs, one for each level. Conversely, in the case of a strong dependence between the levels, each column of γ will have one coefficient close to one, the others being close to 0. Therefore, the individuals affiliated to organizations belonging to the same block of organizations will be affiliated to one block of individuals. Even if the γ's imply a dependent relationship between the two levels, the connections of the corresponding blocks at the two levels may have different connectivity patterns since there is no constraint on the corresponding connection parameters α O and α I .

Identifiability

The identifiability conditions for the MLVSBM are given in the following proposition. Proposition 2.2. The MLVSBM is identifiable up to label switching under the following assumptions:

1 2 3 4 5 α O •• α O •• α O •• 1 2 3 4 5 6 7 α I •• α I •• α I •• α I ••
A1. All coefficients of α I • γ • π O are distinct and all coefficients of α O • π O are distinct. A2. n I ≥ 2Q I and n O ≥ max(2Q O , Q O + Q I -1).

A3. At least 2Q I organizations contain one individual or more.

The set of parameters that does not verify assumption A1 has null Lebesgue measure.

Assumption A2 is very weak in practice. Assumption A3, on the affiliation, means that at least some organizations must not be empty and enough individuals belong to different organizations. The proof of this proposition is provided in 2.B and results from an extension of the proof given in Celisse et al. (2012).

Statistical Inference

We now present a maximum likelihood procedure and a criterion for model selection.

Statistical Inference 51

Variational method for maximum likelihood estimation

As said before, θ (X|A) is obtained by integrating out the latent variables Z in the complete data likelihood (2.6). However, this calculus becomes not computationally tractable as the numbers of nodes and blocks increase.

The Expectation-Maximization algorithm (EM) [START_REF] Dempster | Maximum likelihood from incomplete data via the em algorithm[END_REF] is a popular solution to maximize the likelihood of models with latent variables. However it requires the computation of P θ (Z|X, A) which is also not tractable in our case. The variational version of the EM algorithm is a powerful solution for such cases. It was first used for the SBM by [START_REF] Daudin | A mixture model for random graphs[END_REF].

In a few words, the variational EM algorithm maximizes the so-called variational bound i.e. a lower bound of the log-likelihood denoted J θ (R(Z|A)) and defined as follows:

J θ (R(Z|A)) := E R [ θ (Z, X|A)] + H (R(Z|A)) (2.7) = θ (X|A) -KL (R(Z|A) P θ (Z|X, A)) ≤ θ (X|A),
where KL is the Kullback-Leibler divergence, H is the Shannon entropy: H(P ) = E P [-log(P )] and R(Z|A) is an approximation of the true distribution P θ (Z|X, A). In our context, and following [START_REF] Daudin | A mixture model for random graphs[END_REF], we propose to choose R(Z|A) in a family of factorized distributions, resulting into a mean field approximation R(Z|A) defined as:

R(Z|A) = n I i=1 Q I k=1 (τ I ik ) 1 Z I i =k n O j=1 Q O l=1 (τ O jl ) 1 Z O j =l , ( 2.8)
where

τ I ik = P R (Z I i = k) and τ O jl = P R (Z O j = l).
Inputting Equations (2.6) and (2.8) into Equation (2.7), the variational bound for the MLVSBM can be written as follows:

J θ (R(Z|A)) = j,l τ O jl log π O l + i,k τ I ik j,l A ij τ O jl log γ kl + 1 2 i =i k,k τ I ik τ I i k log φ X I ii , α I kk + 1 2 j =j l,l τ O jl τ O j l log φ X O jj α O ll - i,k τ I ik log τ I ik - j,l τ O jl log τ O jl .
The variational EM algorithm consists in iterating two steps.

Step VE maximizes the variational bound with respect to the parameters of the approximate distribution defined in Equation (2.8). This is equivalent to minimizing the Kullbach-Leibler divergence term.

Step M maximizes the variational bound with respect to the model parameters θ. The procedure is given in Algorithm 2 and details of the calculus and algorithm are developed in 2.C. Algorithm 2 can be slightly modified to handle missing data (dyads which are not observed in any of the two levels) by summing up on observed dyads only. An interesting feature of the MLVSBM is to make use of one level to help the prediction of missing dyads of the other level. A Stochastic Block Model for the Analysis of Multilevel Networks

Remark. Although the family of the variational distributions does not consider the affiliation matrix A, the minimization of the Kullback-Leibler divergence between the variational distribution and P θ (Z|X, A) induces an indirect dependence on

A in the variational distribution. One may consider more complex distributions but the simulation studies show that the inference algorithm is able to retrieve properly the dependence between the Z I s and the Z O s in this family of distributions.

Algorithm 2: Variational EM algorithm Data: {X, Z, A}, a multilevel network with an initial clustering of size

(Q I , Q O ).
Procedure:

• Set {τ I , τ O } from the initial clustering. while J θ (R(Z|A)) is increasing do • M step compute θ (t+1) = arg max θ J θ (R (t+1) (Z I , Z O |A)),
by updating the model parameters as follows:

π O l = 1 n O j τ O jl α O ll = j =j τ O jl X O jj τ O j l j =j τ I jl τ I j l γ kl = i,j τ I ik A ij τ O jl i,j A ij τ O jl α I kk = i =i τ I ik X I ii τ I i k i =i τ I ik τ I i k . • VE step compute {τ I , τ O } (t+1) = arg max τ I ,τ O J θ (t) (R(Z I , Z O |A))
by updating the variational parameters with the following fixed points relationships:

τ O jl ∝π O l i,k γ A il τ I ik kl j =j l φ(X O jj , α O ll ) τ O j l τ I ik ∝ j,l γ A il τ O jl kl i =i k φ(X I ii , α I kk ) τ I i k . return J θ (R(Z|A)), θ and { τ I , τ O }

Model selection

Selection of the number of blocks

Following [START_REF] Biernacki | Assessing a mixture model for clustering with the integrated completed likelihood[END_REF] and [START_REF] Daudin | A mixture model for random graphs[END_REF], we propose a model selection criterion to choose the unknown number of blocks Q I and Q O . The ICL criterion is an integrated version of BIC applied to the complete likelihood. In other words, it is an asymptotic approximation of the complete likelihood integrated over its parameters and latent variables, it values both goodness of fit and classification sharpness [START_REF] Mariadassou | Uncovering latent structure in valued graphs: a variational approach[END_REF].

Our criterion is equal to:

ICL MLVSBM (Q I , Q O ) = log θ (X I , X O , Z I , Z O |A, Q I , Q O ) -pen MLVSBM (Q I , Q O ), (2.9) where pen MLVSBM (Q I , Q O ) = 1 2
Q I (Q I + 1) 2 log n I (n I -1) 2 + Q O (Q I -1) 2 log n I + 1 2 Q O (Q O + 1) 2 log n O (n O -1) 2 + Q O -1 2 log n O , (2.10)
where Z O and Z I are the imputed latent variables using the maximum a posteriori (MAP) of P θ(Z|X, A; Q I , Q O ). The calculus is provided in 2.D. As for the variational inference, P θ(Z|X, A; Q I , Q O ) is unknown and, in practice, we replace it by its mean-field approximation R θ(Z|A;

Q I , Q O ).
Remark. Once again, note that the penalty (2.10) is adapted to undirected networks. For instance, the term

Q I (Q I +1) 2 log n I (n I -1)
2 would become Q 2 I log n I (n I -1) if X I were not symmetric. Remark. We recall that the penalty of the ICL for a (unilevel) SBM is given by

pen SBM (Q) = 1 2 Q(Q + 1) 2 log n(n -1) 2 + Q -1 2 log n. (2.11)
The penalty term in Equation (2.10) for the inter-organizational level is the same as the one given in Equation (2.11). For the inter-individual network, the factor in front of log [START_REF] Bianconi | Multilayer Networks: Structure and Function[END_REF], that is the penalty term which corresponds to the degree of freedom of γ.

n I is Q O (Q I -1) instead of Q I -1 for the SBM as in Equation (2.

Determining the independence between levels

The ICL criterion can also be used to assess whether the two levels of interactions are independent or not. If γ is forced to have all its columns identical, then the penalty term on γ becomes 1 2 (Q I -1) log n I and, as a consequence:

ICL Ind (Q I , Q O ) = ICL I SBM (Q I ) + ICL O SBM (Q O ). ( 2

.12) A Stochastic Block Model for the Analysis of Multilevel Networks

The ICL criterion favors independence if max

{Q I ,Q O } ICL MLVSBM (Q I , Q O ) ≤ max Q I ICL I SBM (Q I ) + max Q O ICL O SBM (Q O ).
If this is the case, then the gain in terms of likelihood does not compensate the gain

1 2 (Q O -1)(Q I -1)
log n I in the penalty. This criterion focuses on the dependence between levels given by the inter-level.

Remark.

If Q I = 1 or Q O = 1, the MLVSBM is the product of two independents SBM, as such ICL Ind (Q I , Q O ) = ICL MLVSBM (Q I , Q O ).

Procedure for model selection

We now provide a procedure for model selection which seeks for the optimal number of blocks at a reasonable cost. As a by-product, it states whether the two levels are independent or not.

The practical choice of the model and the estimation of its parameters are computationally intensive tasks. Indeed, we should compare all the possible models -one model corresponding to a given (Q I , Q O ) -through the ICL criterion. Furthermore, for each model, the variational EM algorithm should be initialized at a large number of initialization points (due to its sensitivity to the starting point), resulting in an unreasonable computational cost. Instead, we propose to adopt a stepwise strategy, resulting in a faster exploration of the model space, combined with efficient initializations of the variational EM algorithm. The procedure we suggest is given in Algorithm 3.

Algorithm 3: Model selection algorithm

Data: {X I , X O , A}, a multilevel network.

Procedure:

• Infer independent SBMs on X I and X O for a respective range of Q I and

Q O . Deduce Q I Ind = arg max Q I ICL I SBM (Q I ) and Q O Ind = arg max Q O ICL O SBM (Q O ). Compute ICL Ind = ICL I SBM ( Q I Ind ) + ICL O SBM ( Q O Ind ). • Start at Q I = Q I Ind and Q O = Q O Ind .
while ICL is increasing do -Fit an MLVSBM on every model of size (Q I ± 1, Q O ± 1) initialized by merging 2 blocks or splitting a block with hierarchical clustering. -Among all estimated models, keep the one with the highest ICL.

return ( Q I , Q O ) = arg max ICL(Q I , Q O ), θ ( Q I , Q O ) and Z.
Each step of the algorithm requires O(max{Q I , Q O } 2 ) variational EM algorithms which converge in a few iterations as a result of the local initialization. Inferring an independent SBM on each level beforehand is a fast way to start with good initialization and allows us to state on the independence of the model at the same time as we just need to compare the sum of the ICL Ind and ICL MLVSBM (

Q I , Q O ).
Package All the codes are available as an R package at https://chabertliddell.github.io/MLVSBM/. It features the simulation and inference of multilevel networks with symmetric and/or asymmetric adjacency matrices, model and independence selection. It also handles missing at random data [START_REF] Rubin | Inference and missing data[END_REF]) on the adjacency matrices of one or both levels and link prediction.

Illustration on simulated data

In this section, we study the performances of the inference procedure for the MLVSBM including the ability to recover blocks, the selection of the numbers of blocks and the independence detection. Remark. In order to evaluate the ability to recover blocks, we resort to the Adjusted Rand Index (ARI) [START_REF] Hubert | Comparing partitions[END_REF] which is a comparison index between two clusterings with a correction for chance. This index is close to 0 when the two clusterings are independent and is 1 when the clusterings are identical (up to label switching). Remark. In our results, we focus on the ability to recover blocks rather than on the quality of the model parameter estimates since it is the hardest task. Indeed, once the blocks are recovered (ARI=1), the estimation of the model parameters boils down to the computation of the proportions of observed links between blocks which is a consistent estimator in a Bernoulli i.i.d. model.

Experimental design

In what follows, we set Let d be a density parameter: the lower d, the sparser the network and the harder the inference. (≥ 1) is a parameter tuning the strength of the communities; when is high, the communities are easily separable. In the simulation study, we focus on the three following standard topologies.

Q O = Q I = 3.
• Assortative communities. The probability of connection within communities is higher than the probability of connection between communities:

α I = d *    1 1 1 1 1 1   . A

Stochastic Block Model for the Analysis of Multilevel Networks

• Disassortative communities. The probability of connection within communities is lower than the probability of connection between communities:

α I = d *    1 1 1   .
• Core-periphery. A core block is highly connected to the whole network while the probability of connection in the periphery is low:

α I = d *    1 1 1 1 1 1   .
We fix the topology of the inter-organizational level X O to be an assortative communities with d = 0.1, = 5 and of communities of equal size on average. We expect this topology to be easy to infer and to obtain a perfect recovery of the clustering with high probability.

For the inter-individual level, d is set to 0.01, 0.05 or 0.1 while ranges from 1 to 10 by stepize of 0.5. = 1 corresponds to an Erdős-Rényi graph and the communities should be indistinguishable. The affiliation matrix A is generated from a power-law distribution in order to get different sizes of organizations. Other distributions were tried but the results (not reported here) show that their impact on the inference is weak.

Finally, δ is a parameter for the strength of the dependence between levels, ranging from 0 to 1. More precisely, we set:

γ =    δ 1 2 (1 -δ) 1 2 (1 -δ) 1 2 (1 -δ) δ 1 2 (1 -δ) 1 2 (1 -δ) 1 2 (1 -δ) δ   
where γ has been defined in Equation (2.4). δ = 1/Q I corresponds to the case of independence between levels. The further δ is from 1/Q I , the stronger the dependence between levels. δ = 1 implies a deterministic link between the clustering of the two levels, ie. the block of an individual is fully determined by the block of his/her organization. With this experimental design we aim to exhibit how the inference is improved by applying the MLVSBM rather than the SBM when the two levels are intertwined.

Simulation results

During the inference procedure, the number of blocks is unknown for both levels. We run the model selection for

Q I ∈ {1, . . . , 10} and Q O ∈ {1, . . . , 10}.
First, we fix δ = 0.8 and make vary. Each situation is simulated 50 times. We test the ability of our model to recover the true clustering of Z I from (X I , X O ). We compare our performances to the ones obtained by applying a standard (unilevel) SBM on X I . Because (Q I , Q O ) are assumed to be unknown, two types of error may occur: one for not selecting the right Q I and one for assigning nodes to the wrong blocks. The results are displayed in Figure 2.4.

In Figure 2.4 A, we plot -for 3 values of density d and the 3 topologies (assortative, core-periphery and disassortative) -the ARI when using MLVSBM (plain line) and SBM (dashed line) as ε varies. We observe that, for any topology, the MLVSBM starts to recover perfectly the clustering for a lower value of than the SBM because in the MLVSBM, the inter-individual level benefits from the information held in the inter-organizational level through the dependence of their blocks. The difficulty of the inference increases as decreases: as can be seen in Figure 2.4 A, MLVSBM still performs well (ARI > 0) for small values of while the SBM is unable to recover the clustering.

In Figures 2.4 B and C, we plot the number of blocks chosen by the MLVSBM (B) and the SBM (C) for 3 values of density (rows) and 3 topologies (columns) (the true value being Q I = 3). We observe that using the MLVSBM allows to recover more precisely Q I than using the SBM. Q I varies from 1, when no structure is detected to 3 which is the true number of blocks. The procedure never selects more blocks than expected, which is coherent with prior knowledge that the ICL for the SBM tends to select models of smaller size [START_REF] Hayashi | A tractable fully bayesian method for the stochastic block model[END_REF][START_REF] Brault | Estimation et sélection de modèle pour le modèle des blocs latents[END_REF]. On the three topologies with = 3, depending on the density d, MLVSBM and A Stochastic Block Model for the Analysis of Multilevel Networks SBM supply Z I either a perfect recovery of the clustering or a random clustering or something in between. In order to understand better this phenomenon, we fix to 3 and make δ -which quantifies the dependency between the two levels -vary. The results are reported in Figure 2.5 for 50 simulations of each situation.

When δ = 1/3 (yellow vertical line in Figure 2.5 A), the two levels are independent and the results in terms of clustering are the same for the MLVSBM and the SBM on X I (see ARI in Figure 2.5 A). As soon as δ departs from this value, the MLVSBM is able to recover some of the structure of the inter-individual level thanks to the inter-organizational level and this ability is observed even for very low density when δ gets closer to 1 (see Figure 2.5 A and B).

Figure 2.5.C depicts the performances of the ICL criterion to state on the independence between the two levels. For d = 0.01, X I is very sparse, Q I = 1 (no structure is detected on the inter-individual level) leading to ICL ind = ICL MLVSBM and preventing us from detecting any dependency. For higher densities, we see as expected, that if δ ≈ 1/3, the independent SBM will be preferred. On the contrary the further δ departs from 1/3 the more the MLVSBM will be selected, even-though the MLVSBM and the independent SBM may provide the same clusterings. This phenomenon occurs faster for higher density d. In our simulation, the MLVSBM is never selected when δ = 1/3. This is a consequence of the conservative nature of ICL, requiring strong evidence from the likelihood to select a more complex model.

We chose not to present results concerning the inter-organizational level since its structure was selected to be "easy-to-infer". Hence, the SBM and the MLVSBM perform well for selecting the true number of blocks Q O and recovering the block structure. Simulations gave similar results (not reported here) when we inverse the topologies on X I and X O , showing that information on structure transits in both ways. Moreover, when the number of nodes of the "easy-to-infer" level increases, it facilitates the recovering of the clustering on the "hard-to-infer" level. When both levels are "hard-to-infer", the inference of each level benefits from one another if the dependence between the two levels is strong enough. One can exhibit cases where the unilevel SBM is unable to recover the clustering of any of the two levels but where the MLVSBM succeeds in recovering the true blocks for both. Detailed results for such a simulation study are available on the MLVSBM R package website https://chabert-liddell.github.io/MLVSBM/articles/hard_to_infer.html.

Computational costs

Inferring the blocks and the parameters of a multilevel network is a challenging task which can be time consuming. As a guideline for readers, we present in Table 2

n I n O Q I = Q O = 2 Q I = Q O = 4 Q I = Q O =

Application to the multilevel network issued from a television programs trade fair

We apply our model to the data set (Brailly et al., 2016) described below.

Context and Description of the data set

Promoshow East is a television programs trade fair for Eastern Europe. Sellers from Western Europe and the USA come to sell audiovisual products to regional and local buyers such as broadcasting companies. The data gather observations on one particular audiovisual product, namely animation and cartoons. From a sociological perspective, reconstituting and analyzing multilevel (inter-individual and inter-organizational) networks in this industry is important. In economic sociology, it helps redefine the nature of markets [START_REF] Brailly | Embeddedness as a multilevel problem: A case study in economic sociology[END_REF][START_REF] Brailly | Neo-structural economic sociology beyond embeddedness[END_REF][START_REF] Lazega | Interdependent entrepreneurs and the social discipline of their cooperation: a research programme for structural economic sociology in a society of organizations[END_REF]. In the sociology of culture, it helps understand, from a structural perspective, the mechanisms underlying contemporary globalization and standardization of culture [START_REF] Brailly | Embeddedness as a multilevel problem: A case study in economic sociology[END_REF][START_REF] Favre | Inter-organizational network influence on long-term and short-term inter-individual relationships: The case of a trade fair for tv programs distribution in sub-saharan africa[END_REF]. In the sociology of organizations and collective action, it helps understand the importance of multilevel relational infrastructures for the management of tense competition and cooperation dilemmas by various categories of actors [START_REF] Lazega | Bureaucracy, Collegiality and Social Change: Redefining Organizations with Multilevel Relational Infrastructures[END_REF], in this case the (sophisticated) sales representatives of cultural industries.

Statistical analysis

The MLVSBM is inferred on the two datasets (one dataset corresponding to the deal network at the inter-organizational level, the other dataset to the meeting network at the inter-organizational level). In both cases the ICL criterion favors dependence between the two levels and chooses Q I = 4 blocks of individuals. Q O is equal to 3 for the deal network and 4 for the meeting network.

In order to determine which is the most relevant inter-organizational network, we test the ability of the MLVSBM to predict dyads or links in the inter-individual network when the deal or the meeting networks are considered. To do so, we choose uniformly dyads and links to remove and try to predict them. More precisely, we set X I ii = NA for a certain percentage of (i, i ) (this percentage ranging from 5% to 40% by step-size of 5%). We also propose to remove existing links (ie. forcing X I ii = 0 when X I ii = 1 was observed, for some randomly chosen (i, i )). The percentage of removed existing links varies from 5% to 95% (with step-size of 5%). We repeat the following procedure 100 times:

1. Remove dyads or links uniformly at random 2. Infer the newly obtained network from scratch in order to obtain the probability of a link P(X I ii = 1; θ) for each missing dyad or for each dyad such that X I ii = 0 3. Predict link among all missing dyads or among all dyads such that X I ii = 0. Missing data are handled as Missing At Random [START_REF] Tabouy | Variational inference for stochastic block models from sampled data[END_REF] and the probability of existence of an edge is given by: P(X I ii = 1; θ) = k,k τ I ik α I kl τ I i k . Since the result of our procedure is equivalent to a binary classification problem, we assess the performance through the area under the ROC curve (AUC) (a random classification corresponding to AUC = 0.5). Figure 2.6 shows that using the MLVSBM compared to a single level SBM improves a lot the recovery of the inter-individual level for this dataset. This confirms the dependence between levels detected by the ICL. Moreover, using the deal network gives better predictions for both missing dyads and missing links than the meeting network. We also considered a merged network at the inter-organizational level by making the union of links of the deal and the meeting network, i.e. for all j, j

∈ n O , X O,merged jj = max{X O,deal jj , X O,meeting jj }.
The improvement in terms of prediction over the deal network is not very significant and this composite network is much harder to analyze sociologically. Remark. Another way to simulate missing data is to consider actor non-response like in (Žnidaršič et al., 2012). In our case, it corresponds to selecting a portion of the individuals at random and putting all their out-going dyads to NA (i.e. X I ii = NA for all i if individual i did not respond). Then we look at the stability of the clustering as in Žnidaršič et al. (2012, 2019) (the ARI between the clustering of the individuals with the full data and the one with the missing data). By doing so, we notice in simulations (not reported here) that the clustering of the individuals is more stable when considering an MLVSBM on (X I , X O,deal ) than when considering a unilevel A Stochastic Block Model for the Analysis of Multilevel Networks SBM on X I . This is one more clue in favor of the dependence between the two levels. Remark. Žiberna (2019) and Žiberna (2020) also deals with this dataset from [START_REF] Brailly | Embeddedness as a multilevel problem: A case study in economic sociology[END_REF]. However, Žiberna (2019) uses the dataset collected in 2012 and Žiberna (2020) gathers the datasets collected in 2011 and 2012 while we only use the 2011 dataset. Moreover, different choices were made on the individuals and organizations to include or not. Thus, a direct comparison does not make sense. Applying Žiberna's method on the dataset we consider provides us with clusterings that somewhat agree on both levels (ARIs>0.6). We have checked that the difference derives from the fact that the two methods do not seek the same patterns.

Analysis and comments

For the analysis, we use the MLVSBM inferred from the deal network. We select Q O = 3 and Q I = 4 blocks and the ICL is in favor of a dependence between the two levels. This network is plotted in Figure 2.7 B and we reordered the adjacency matrices of both levels by blocks in Figure 2.7 C. In Figure 2.7 A, we plot a synthetic view of the blocks of this multilevel network. The size of each node is proportional to the cardinal of each block. For the inter-organizational level, we link blocks of organizations by α O (plain black edges) and by the probability of interactions of their individuals P(X

I ii = 1|Z O A i , Z O A i ) (gradual blue edges).
The donut charts around the nodes is the parameter γ. For the inter-individual level, blocks of individuals are linked by α I and the donut chart for a given block is the apportionment of each block of organizations in the individuals' affiliation.

We can now interpret the block with respect to the actors' covariates shown in Table 2.2. At the inter-organizational level, block 1 (in red) is a residual group composed of 61 organizations that are weakly connected to the rest of the organizations. Block 2 (in orange) consists of customers: broadcasters that come to the trade fair to buy programs and independent buyers who buy programs, planning to sell them later to broadcasters. We observe a non-null intra-block connection, but deals are mainly done between organizations of the blocks 2 and 3 (block 3 in yellow), the latter mostly containing distributors.

At the inter-individual level, blocks 1 and 2 consist of buyers (exclusively for block 1). They differ in their affiliations, both are affiliated to the second block of organizations but a larger proportion of the individuals of block 2 are affiliated to the residual block of organizations. They also differ in the way they connect to blocks 3 and 4. Block 4 is a residual group consisting of roughly half of the individuals. It does not exhibit any particular pattern in its affiliations and is weakly connected, mainly inward connection from block 2. Block 3 consists of sellers giving advices to individuals of block 2 and has reciprocal relationship with individuals of block 1. They are mainly affiliated to producing and distributing companies of block 3 of organizations. It is also the block that has the strongest intra-block connections.

The blue edges in Figure 2.7 A show that the organizations of blocks 2 and 3 and their respective individuals follow the same pattern for their inter-block connections but differ in their intra-block connections. Individuals affiliated to organizations of block 3 have above average intra-block connections while few contracts are signed between their organizations (mainly distributors).

These results confirm neo-structural insights into the functioning of markets. Competition between producers/distributors is strong: they all need to find broadcasting companies and distributors on the buying side. However, most of them arrive to the trade fair without updated information about the products in which buyers are interested in that year, their available budgets for each category of product, their willingness to negotiate, etc. The value of multilevel network analysis that is used here is to show that inter-individual personal relationships between individuals affiliated with competing organizations help manage the tensions between these directly competing organizations (Lazega et al., 2016;[START_REF] Lazega | Theory of cooperation among competitors: A neo-structural approach[END_REF]. This is where personal ties between individuals affiliated in these companies -especially among sellers and buyers, but also less visibly among sellers -are important: they help manage the strong tensions between companies by creating coopetition, i.e. cooperation among their competing firms. Here, social/advice ties between buyers (blocks 1 and 2 of individuals) affiliated to buying companies in block 2 of organizations (broadcasting companies and distributors) exchange advice from sellers of block 3 representing production and distribution companies: this is the normal, stabilized, overlapping, commercial ties between companies embedded in social ties between representatives.

As seen above, block 3 has strong intra-block connections which may signal discreet coordination efforts between sellers as shown by Brailly (2016); Brailly et al. ( 2016).

When a seller has closed a deal with a buyer, he/she can advise and update another seller -i.e. a coopetitor in terms of affiliation to a competing company -about other products in which this buyer is interested, what budget is left in his/her pocket, i.e. precious information for the next sellers. This kind of personal service is expected to be reciprocated over the years; otherwise the relationship decays. This is the most unexpected phenomenon from an orthodox economic perspective and should lead to new perspectives in neo-structural economic sociology [START_REF] Lazega | Interdependent entrepreneurs and the social discipline of their cooperation: a research programme for structural economic sociology in a society of organizations[END_REF].

This cross-level interdependence between inter-organizational ties and interindividual ties is strong enough for companies to be unable to lay off its sales representatives. Having long tried to replace costly trade fairs with online websites A Stochastic Block Model for the Analysis of Multilevel Networks and catalogues, companies realized that they still need the service that real persons and their personal relational capital provide in terms of multilevel management of coopetition (Lazega, 2020).

Discussion

In this paper, we propose an SBM for multilevel networks. We develop variational methods for the inference of the model and a criterion that allows us to choose the number of blocks and to state on the independence between the levels at the same time. There are clear advantages at considering a joint modeling of the two levels over an independent model for each level. Indeed, we show on some simulation studies that when we detect dependence between levels, it helps us to recover the block structure of a level with low signal thanks to the structure of the other level and also to improve the prediction of missing links or dyads. On the trade fair dataset, this joint modeling brought us a synthetic representation of the two networks unraveling their intertwined structure and provide new insights on the social organization.

In lieu of a Bernoulli distribution, the edge distribution of any level may be extended to a valued distribution and/or to include edge covariates in a similar way as for the SBM [START_REF] Mariadassou | Uncovering latent structure in valued graphs: a variational approach[END_REF]. One way to account for the degree distribution would be to use nodes degrees as covariates, another would be to rewrite the edge distribution as the Degree Corrected SBM [START_REF] Karrer | Stochastic blockmodels and community structure in networks[END_REF]. Our choice to model the interaction levels given the affiliations (A being fixed) is driven by the fact that, in a lot of applications, these affiliations are known and the object of the analysis is the interactions. We choose to consider a unique affiliation per individual since this was the case on the datasets available to us, but this approach could be extended to a less restricted number of affiliations (this model is implemented in our R package). We could even consider any hierarchical structure such as multiscale networks to model the levels given the hierarchy or more generally multilayer networks by modeling the layers given the inter-layers. 2009). Indeed, one might imagine that the data of one level may be easier to collect or to verify than the other one (for instance because it is public, already exists or is cheaper to collect). Thus, we think that this approach could be used to leverage the interdependence in a multilevel network in order to compensate for some missing or spurious information on a given level which is known to be difficult to observe. A Stochastic Block Model for the Analysis of Multilevel Networks

2.A. Proof of Proposition 2.1

Proposition 2.1. In the MLVSBM, the two following properties are equivalent:

1. Z I is independent on Z O , 2. γ kl = γ kl ∀l, l ∈ {1, . . . , Q O },
and imply that:

3. X I and X O are independent.

Proof. We first derive an expression for γ (Z I ) = γ (Z I |A):

γ (Z I |A) = Z O γ (Z I |A, Z O )dP(Z O ) = l 1 ,...,ln O γ (Z I |A, Z O 1 = l 1 , . . . , Z O n O = l n O )P(Z O 1 = l 1 , . . . , Z O n O = l n O ) = l 1 ,...,ln O j i γ (Z I i |A, Z O A i = l A i ) P(Z O j = l j ) = l 1 ,...,ln O j   i,k γ 1 Z I i =k A ij kl j   π O l j = j l i,k γ A ij 1 Z I i =k kl π O l where A i = {j : A ij = 1}.
2. ⇒ 1.: Assume that γ kl = γ kl ∀l, l ∈ {1, . . . , Q O }, then:

γ (Z I |Z O , A) = k,l γ i,j A ij 1 Z I i =k 1 Z O j =l kl = k γ i,j A ij 1 Z I i =k l 1 Z O j =l k1 = i,k γ 1 Z I i =k k1
, and

γ (Z I |A) = j l i,k γ A ij 1 Z I i =k kl π O l = j i,k γ A ij 1 Z I i =k k1 l π O l = i,k γ 1 Z I i =k k1 , hence γ (Z I |Z O , A) = γ (Z I |A). 1. ⇒ 2.: Assume that γ (Z I |Z O , A) = γ (Z I |A) for any values of Z I , Z O , then in particular γ (Z I 1 |Z O , A) = γ (Z I 1 |A).
Assuming that individual 1 belongs to organization j, we can write, for any k:

P(Z I 1 = k|Z O j , A ij = 1) = γ kZ O j . 69
However, this quantity does not depend on Z O j so γ kZ O j = γ k• for any value of k and Z O j . And so we have γ kl = γ kl for any (l, l ).

1. ⇒ 3.:

α I ,α O (X I , X O |A) = z I ,z O α I ,α O (X I , X O |A, Z I = z I , Z O = z O )P(Z I = z I , Z O = z O )dz I dz O = z I ,z O α I (X I |Z I = z I )P(Z I = z I |A, Z O = z O ) α O (X O |Z O = z O )P(Z O = z O )dz I dz O = z I α I (X I |Z I = z I )P(Z I = z I )dz I z O α O (X O |Z O = z O )P(Z O = z O )dz O = α I (X I ) α O (X O )
which is the definition of the independence.

2.B. Proof of Proposition 2.2 Proposition 2.2. The stochastic block model for multilevel networks is identifiable up to label switching under the following assumptions:

A1. All coefficients of α I • γ • π O are distinct and all coefficients of α O • π O are distinct. A2. n I ≥ 2Q I and n O ≥ max(2Q O , Q O + Q I -1).
A3. At least 2Q I organizations contain one individual or more.

Proof. Let θ = {π O , γ, α I , α O } be the set of parameters and P X the distribution of the observed data. We will prove that there is a unique θ corresponding to P X . More precisely, in what follows, we will compute the probabilities of some particular events, from which we will derive a unique expression for the unknown parameters.

The beginning of the proof -identifiability of π O and α O -is mimicking the one given in [START_REF] Celisse | Consistency of maximumlikelihood and variational estimators in the stochastic block model[END_REF]. The last steps of the proof are original work.

Notations. For the sake of simplicity, in what follows, we use the following shorten notation:

x i:k := (x i , . . . , x k ), X j,i:k = (X ji , . . . , X jk ) .
Moreover, {X j,i:k = 1} stands for {X ji = 1, . . . , X jk = 1}.

Identifiability of π O For any l = 1, . . . , Q O , let τ l be the following probability:

τ l = P(X O ij = 1|Z O i = l) = l α O ll π O l = (α O • π O ) l , ∀(i, j). (2.B.13)
Moreover, a quick computation proves that

P(X O i,j:(j+k) = 1|Z O i = l) = τ k+1 l (2.

B.14) A Stochastic Block Model for the Analysis of Multilevel Networks

According to Assumption A1, the coordinates of vector (τ 1 , . . . , τ Q O ) are all different. Hence, the Vandermonde matrix

R O of size Q O × Q O such that R O il = (τ l ) i-1 , 1 ≤ i ≤ Q O , 1 ≤ l ≤ Q O is invertible.
We define u O i as follows:

u O i = P X,θ (X O 1,2:(i+1) = 1) for 1 ≤ i ≤ 2Q O -1 u O 0 = 1. The existence of (u O i ) i=0,...,2Q O -1 comes from Assumption A2 (n O ≥ 2Q O ). Moreover, the (u O i ) i=0,.
..,2Q O -1 are calculated from the marginal distribution P X . We will use these quantities to identify the parameters (π O , α O ).

First we have, for 1 ≤ i ≤ 2Q O -1:

u O i = Q O l=1 P(X O 1,2:(i+1) = 1|Z O 1 = l)P(Z O 1 = l) = Q O l=1 τ i l π O l , using Equation (2.B.14). Now, let us define M O a (Q O + 1) × Q O matrix such that: M O ij = u O i+j-2 = Q O l=1 τ i-1 l π O l τ j-1 l , 1 ≤ i ≤ Q O + 1, 1 ≤ j ≤ Q O . ( 2
B O (x) = Q O k=0 (-1) k+Q O δ k+1 x k . (2.B.16) • B O is of degree Q O . Indeed, δ Q O +1 = det(M O -(Q O +1) ) and M -(Q O +1) = R O D π O R O where D π O = diag(π O ). As a consequence, M O -(Q O +1
) is the product of invertible matrices then δ Q O +1 = 0 and we can conclude.

• Moreover, ∀l = 1, . . . , Q O , B O (τ l ) = 0 . Indeed, B O (τ l ) = det(N O l ) where N O l is the concatenated matrix N O l = M O | V l with V l = [1, τ l , . . . , τ Q O l
] (computation of the determinant development against the last column). However, from Equation (2.B.15), we have

M O •j = l τ j-1 l π O l V l , i.e. each column vector of M O is a linear combination of V 1 , . . . , V Q O . As a consequence, ∀l = 1, . . . , Q O , N O l is of rank < Q O + 1
, and so B O (τ l ) = 0. The (τ l ) l=1,...,Q O being the roots of B, they can be expressed in a unique way (up to label switching) as functions of (δ k ) k=0,...,Q O , which themselves are derived from P X,θ . As a consequence, the identifiability of R O is derived from the identifiability of (τ l ) l=1,...,Q O . Using the fact that

D π O = R O -1 M O -Q O R O -1
, we can identify π O in a unique way.

Identifiability of α

O For 1 ≤ i, j ≤ Q O , we define U ij as follows: U O ij = P(X O 1,2:(i+1) = 1, X O 2, (n O -j+2):n O = 1) with U O i1 = P(X O 1,2:(i+1) = 1). U O i,j = l 1 ,l 2 τ i-1 l 1 π O l 1 α O l 1 l 2 π O l 2 (τ l 2 ) j-1 , ∀1 ≤ i, j ≤ Q O ,
and as consequence

U O = R O D π O α O D π O R O . D π O
and R O being invertible, we get:

α O = D -1 π O R O -1 U O R O -1 D -1 π O . And so U O is uniquely derived from P X , so α O is identified.
Identifiability of α I To identify α I , we have to take into account the affiliation matrix A. Without loss of generality, we reorder the entries of both levels such that the affiliation matrix A has its 2Q I × 2Q I top left block being an identity matrix (Assumption A3).

• For any k = 1 . . . , Q I and for i = 2, . . . , 2Q I , let σ k be the probability

P(X I 1i = 1|Z I 1 = k, A), A being such that A jj = 1, ∀j = 1, . . . , 2Q I . σ k = P(X I 1i = 1|Z I 1 = k, A) = k P(X I 1i = 1|Z I 1 = k, Z I i = k )P(Z I i = k |Z I 1 = k, A) .
Moreover,

P(Z I i = k |Z I 1 = k, A) = l P(Z I i = k |Z O i = l, Z I 1 = k, A)P(Z O i = l|Z I 1 = k, A) = l γ kl P(Z O i = l|Z I 1 = k, A) . (2.B.17)
However, by Bayes' formula

P(Z O i = l|Z I 1 = k, A) = P(Z I 1 = k|Z O i = l, A)P(Z O i = l) P(Z I 1 = k, A)
.

Taking into the fact that i = 1 and A is such that 1 belongs to organization 1 and i to organization i, we have:

P(Z I 1 = k|Z O i = l, A) = P(Z I 1 = k|A).
And so

P(Z O i = l|Z I 1 = k, A) = P(Z O i = l|A) = π O l .
Consequently, from Equation (2.B.17), we have:

P(Z I i = k |Z I 1 = k, A) = l γ k l π O k A Stochastic Block
Model for the Analysis of Multilevel Networks and so:

σ k = k P(X I 1i = 1|Z I 1 = k, Z I i = k ) l γ k l π O k = k l α I kk γ k l π O l = (α I • γ • π O ) k = (α I • π I ) k , where π I = γ • π O .
• Now, we prove that ∀i = 1, . . . , 2Q I -1,

P(X I 1,2:(i+1) = 1|Z I 1 = k, A) = σ i k . (2.B.18)
Indeed,

P(X I 1,2:(i+1) = 1|Z I 1 = k, A) = k 2:(i+1) P(X I 1,2:(i+1) = 1|Z I 1:(i+1) = (k, k 2:(i+1) ), Z I 1 = k)P(Z I 2:(i+1) = k 2:i+1 |Z I 1 = k, A) = k 2:(i+1) P(X I 1,2:(i+1) = 1|Z I 1:(i+1) = (k, k 2:(i+1) ))P(Z I 2:(i+1) = k 2:i+1 |A) = k 2:(i+1) P(X I 1,2:(i+1) = 1|Z I 1:(i+1) = (k, k 2:(i+1) )) l 2:(i+1) P(Z I 2:(i+1) = k 2:(i+1) , Z O 2:(i+1) = l 2:(i+1) , A).
Note that, to go from line 2 to line 3, we used the fact that P(Z

I 2:(i+1) = k 2:i+1 |Z I 1 = k, A) = P(Z I 2:(i+1) = k 2:i+1 |A)
, which is due the the particular structure of A (left diagonal block of size at least 2Q I , i.e. for any i = 1, . . . , 2Q I , individual i belongs to organization i ). Moreover, we can write:

P(Z I 2:(i+1) = k 2:(i+1) , Z O 2:(i+1) = l 2:i+1 |A) =   λ=2,...i+1 P(Z I λ = k λ |Z O λ = l λ )P(Z O λ = l λ )   =   λ=2,...i+1 γ k λ l λ π O λ   .
Moreover, by conditional independence of the entries of the matrix X I given the clustering we have:

P(X I 1,2:(i+1) = 1|Z I 1 = k, Z I 2:(i+1) = k 2:(i+1) ) = λ=2,...i+1 α I kk λ .
As a consequence,

P(X I 1,2:(i+1) = 1|Z I 1 = k, A) = k 2:(i+1) ,l 2:(i+1) λ=2,...i+1 α I kk λ γ k λ l λ π O λ = λ=2,...i+1 k λ ,l λ α I kk λ γ k λ l λ π O λ = σ i k
• Then we define (u I i ) i=0,...,2Q I -1 , such that u I 0 = 1 and ∀1 ≤ i ≤ 2Q I -1:

u I i = P(X I 1,2:(i+1) = 1|A) = k,l P(X I 1,2:(i+1) = 1|Z I 1 = k)P(Z I 1 = k|Z O 1 = l, A)P(Z O 1 = l) = k σ i k l γ kl π O l =π I k = k σ i k π I k .
Note that the (u I )'s can be defined because n I ≥ 2Q I (assumption A2).

• To conclude we use the same arguments as the ones used for the identifiability of α O , i.e. we define

M I a (Q I + 1) × Q I matrix such that M I ij = u I i+j-2
together with the matrices M I -k and the polynomial function

B I (see Equation (2.B.16)). Let R I be a Q I ×Q I matrix such that R I ik = σ i-1 k . R I is an invertible Vandermonde matrix because of assumption A1 on α I •γ •π O . As before, R I can be identified in unique way from B I . Then, noting that M I -(Q I +1) = R I D π I R I where D π I = diag(π I ) = diag(γ • π O ), we obtain: D π I = (R I ) -1 M I -Q I (R I -1
), which is uniquely defined by P X . Now, let us introduce

U I ij = P(X I 1,2:(i+1) = 1, X I 2, (n I -j+2):n I = 1)
with U I i1 = P(X I 1,2:(i+1) = 1). Then we have

U I = R I D π I α I D π I R I and so α I = D -1 π I (R I ) -1 U I (R I ) -1 D -1 π I . As a consequence, α I is uniquely identified from P X . Identifiability of γ For any 2 ≤ i ≤ Q I and 2 ≤ j ≤ Q O , let U IO i,j be the probability that X I 1,2:i = 1 and X O 1,(i+1):(i+j-1) = 1. Note that the U IO i,j can be defined because n O ≥ Q I + Q O -1 and n I ≥ Q I (assumption A2). • Then, for all 2 ≤ i ≤ Q I and 2 ≤ j ≤ Q O , U IO ij = P(X I 1,2:i = 1, X O 1,(i+1):(i+j-1) = 1|A) = k,l P(X I 1,2:i = 1, X O 1,(i+1):(i+j-1) = 1|A, Z I 1 = k, Z O 1 = l) ×P(Z I 1 = k, Z O 1 = l, A) . (2.B.19)
• We first prove that :

P(X I 1,2:i = 1, X O 1,i+1:i+j-1 = 1|A, Z I 1 = k, Z O 1 = l) = σ i-1 k τ j-1 l . (2.

B.20) A Stochastic Block Model for the Analysis of Multilevel Networks

Indeed,

P(X I 1,2:i = 1, X O 1,(i+1):(i+j-1) = 1|A, Z I 1 = k, Z O 1 = l) = = k 2:i ,l 2:n O P(X I 1,2:i = 1, X O 1,(i+1):(i+j-1) = 1|Z I 1:i = (k, k 2:i ), Z O = (l, l 2:n O ), A) × P(Z I 2:i = k 2:i , Z O 2:n O = l 2:n O |Z I 1 = k, Z O 1 = l, A) = k 2:i ,l 2:n O P(X I 1,2:i = 1|Z I 1:i = (k, k 2:i )) × P(X O 1,(i+1):(i+j-1) = 1|Z O 1 = l, Z O (i+1):(i+j-1) = l (i+1):(i+j-1) ) × P(Z I 2:i = k 2:i , Z O 2:n O = l 2:n O |Z I 1 = k, Z O 1 = l, A) . (2.B.21)
Moreover, let us have a look at P(Z

I 2:i = k 2:i , Z O = l 2:n O |Z I 1 = k, Z O 1 = l, A): P(Z I 2:i = k 2:i , Z O 2:n O = l 2:n O |Z I 1 = k, Z O 1 = l, A) = P(Z I 2:i = k 2:i |Z O 2:n O = l 2:n O , Z I 1 = k, Z O 1 = l, A) × P(Z O 2:n O = l 2:n O |Z I 1 = k, Z O 1 = l, A) .
Because A has a diagonal block of size ≥ Q I , we have, for any i = 1, . . . , Q I , A ij = 1 if j = i, 0 otherwise, we have

• P(Z I 2:i = k 2:i |Z O 2:n O = l 2:n O , Z I 1 = k, Z O 1 = l, A) = P(Z I 2:i = k 2:i |Z O 2:i = l 2:i ), • P(Z O 2:n O = l 2:n O |Z I 1 = k, Z O 1 = l, A) = P(Z O 2:n O = l 2:n O ) .
As a consequence,

P(Z I 2:i = k 2:i , Z O 2:n O = l 2:n O |Z I 1 = k, Z O 1 = l, A) = P(Z I 2:i = k 2:i |Z O 2:i = l 2:i )P(Z O 2:i = l 2:i )P(Z O (i+1):(i+j-1) = l (i+1):(i+j-1) ) ×P(Z O (i+j):n O = l (i+j):n O ) .
Going back to Equation (2.B.21) and decomposing the summation we obtain:

P(X I 1,2:i = X O 1,(i+1):(i+j-1) = 1|A, Z I 1 = k, Z O 1 = l) = k 2:i ,l 2:n O P(X I 1,2:i = 1|Z I 1:i = (k, k 2:i )) × P(X O 1,(i+1):(i+j-1) = 1|Z O 1 = l, Z O (i+1):(i+j-1) = l (i+1):(i+j-1) ) × P(Z I 2:i = k 2:i |Z O 2:i = l 2:i )P(Z O 2:i = l 2:i )P(Z O (i+1):(i+j-1) = l (i+1):(i+j-1) ) × P(Z O (i+j):n O = l (i+j):n O ) = k 2:i P(X I 1,2:i = 1|Z I 1:i = (k, k 2:i )) l 2:i P(Z I 2:i = k 2:i |Z O 2:i = l 2:i )P(Z O 2:i = l 2:i ) l (i+1):(i+j-1) P(X O 1,(i+1):(i+j-1) = 1|Z O 1 = l, Z O (i+1):(i+j-1) = l (i+1):(i+j-1) )) × P(Z O (i+1):(i+j-1) = l (i+1):(i+j-1) ) =P(Z O (i+1):(i+j-1) =l (i+1):(i+j-1) |Z O 1 =l) l (i+j):n O P(Z O (i+j):n O = l (i+j):n O ) =1 = k 2:i P(X I 1,2:i = 1|Z I 1 = k, Z I 2:i = k 2:i )P(Z I 2:i = k 2:i |A) × P(X O 1,(i+1):(i+j-1) = 1|Z O 1 = l) = k 2:i P(X I 1,2:i = 1|Z I 1 = k, Z I 2:i = k 2:i )P(Z I 2:i = k 2:i |Z I 1 = k, A) ×P(X O 1,(i+1):(i+j-1) = 1|Z O 1 = l) = P(X I 1,2:i = 1|Z I 1 = k, A)P(X O 1,(i+1):(i+j-1) = 1|Z O 1 = l) .
Finally, we have :

P(X I 1,2:i = 1|Z I 1 = k, A) = σ i-1 k , from Equation (2.B.18) P(X O 1,(i+1):(i+j-1) = 1|Z O 1 = l) = τ j-1 l ,
and so, we have proved equality (2.B.20).

• Now,

A 11 = 1 implies P(Z I 1 = k, Z O 1 = l|A) = γ kl π O l and
U IO ij = k,l σ i-1 k γ kl π O l τ j-1 l . Setting U IO 1j = P(X O 1,i+1 = 1, . . . , X O 1,i+j-1 = 1|A) = k,l γ kl π O l τ j-1 l , for j > 1 U IO i1 = P(X I 12 = • • • = X I 1,i = 1|A) = k,l γ kl π O l , for i > 1 U IO 11 = 1
we obtain the following matrix expression for U IO :

U IO = R I γD π O R O

2.C. Details of the Variational EM

The variational bound for the stochastic block model for multilevel network can be written as follows:

I θ (R(Z I , Z O |A)) = j,l τ O jl log π O l + i,k τ I ik j,l A ij τ O jl log γ kl + 1 2 i =i k,k τ I ik τ I i k log φ X I ii , α I kk + 1 2 j =j l,l τ O jl τ O j l log φ X O jj α O ll - i,k τ I ik log τ I ik - j,l τ O jl log τ O jl
The variational EM algorithm then consists on iterating the two following steps. At iteration (t + 1):

VE step compute {τ I , τ O } (t+1) = arg max τ I ,τ O I θ (t) (R(Z I , Z O |A)) = arg min τ I ,τ O KL R(Z I , Z O |A) P θ (t) (Z I , Z O |X I , X O , A) . M step compute θ (t+1) = arg max θ I θ (R (t+1) (Z I , Z O |A)).
The variational parameters are sought by solving the equation:

∆ τ I ,τ O I θ (R(Z I , Z O |A) + L(τ I , τ O ) = 0,
where L(τ I , τ O ) are the Lagrange multipliers for τ I i , τ O j for all i ∈ {1, . . . , n I }, j ∈ {1, . . . , n I }. There is no closed-form formula but when computing the derivatives, we obtain that the variational parameters follow the fixed point relationships:

τ O jl ∝π O l i,k γ A ij τ I ik kl j =j l φ(X O jj , α O ll ) τ O j l τ I ik ∝ j,l γ A ij τ O jl kl i =i k φ(X I ii , α I kk ) τ I i k ,
which are used in the VE step to update the τ I i 's and τ O j 's. On each update, the variational parameters of a certain level depend on both the parameter γ and the variational parameters of the other level, which emphasizes the dependency structure of this multilevel model and the role of γ as the dependency parameter of the model. Notice also that when γ kl = γ kl = π I k for all l, l , that is the case of independence between the two levels then we can rewrite the fixed point relationships as follows:

τ O jl ∝π O l j =j l φ(X O jj , α O ll ) τ O j l and τ I ik ∝ π I k i =i k φ(X I ii , α I kk ) τ I i k ,
which is exactly the expression of the fixed point relationship of two independent SBMs. Then, for the M step, we derive the following closed-form formulae:

π O l = 1 n O j τ O jl α O ll = j =j τ O jl X O jj τ O j l j =j τ I jl τ I j l γ kl = i,j τ I ik A ij τ O jl i,j A ij τ O jl α I kk = i =i τ I ik X I ii τ I i k i =i τ I ik τ I i k
for which the gradient

∆ θ I θ (R(Z I , Z O |A)) + L(π O , γ) , is null. The term L(π O , γ) contains the Lagrange multipliers for π O and γ k• for all k ∈ {1, . . . , Q I }.
Model parameters have natural interpretations. π O l is the mean of the posterior probabilities for the organizations to belong to block l. α I kk (resp. α O ll ) is the ratio of existing links over possible links between blocks k and k (resp. l and l ). γ kl is the ratio of the number of individuals in block k that are affiliated to any organization of block l on the number of individuals that are affiliated to any organization of block l. If γ is such that the levels are independent, then any column of γ represents the proportion of individuals in the different blocks:

π I k = γ k1 = 1 n I i τ I ik .

2.D. Details of the ICL criterion

We now derive an expression for the Integrated Complete Likelihood (ICL) model selection criterion. Following [START_REF] Daudin | A mixture model for random graphs[END_REF], the ICL is based on the integrated complete likelihood i.e. the likelihood of the observations and the latent variables where the parameters have been integrating out against a prior distribution. The latent variables (Z I , Z O ) being unobserved, they are imputed using the maximum a posteriori (MAP) or τ . We denote by Z O and Z I the inputed latent variables. After imputation of the latent variables, an asymptotic approximation of this quantity leads to the ICL criterion given in the paper (Equation (2.9)) and recalled here: The marginal complete likelihood is written as follows:

ICL(Q I , Q O ) = log θ (X I , X O , Z I , Z O |A, Q I , Q O ) - 1 2
Q I (Q I + 1) 2 log n I (n I -1) 2 - Q O (Q I -1) 2 log n I - 1 2
Q O (Q O + 1) 2 log n O (n O -1) 2 - Q O -1 2 log n O . A Stochastic Block
log θ (X, Z|A, Q I , Q O ) = log Θ θ (X I , X O , Z I , Z O |θ, A, Q I , Q O )p(θ|Q I , Q O )dθ = log α I (X I |Z I , Q I ) (2.D.22) + log γ (Z I |A, Z O , Q I , Q O ) (2.D.23) + log α O ,π O (X O , Z O |Q O ) .
(2.D.24)

The quantity defined in (2.D.24) evaluated at

Z O := Z O is approximated as in Daudin et al. (2008) by log α O (X O , Z O , Q O ) ≈ n O →∞ log α O , π O (X O , Z O |Q O ) -pen(π O , α O , Q O ) pen(π O , α O , Q O ) = Q O -1 2 log n O + 1 2 Q I (Q I +1) 2 log n I (n I -1) 2 . ( 2
log α I (X I | Z I , Q I ) = n I →∞ log α I (X I | Z I , Q I ) + pen(α I , Q I ) with pen(α I , Q I ) = 1 2 Q I (Q I +1) 2 log n I (n I -1) 2 . ( 2
(Z I |A, Z O , Q I , Q O ): γ (Z I |A, Z O , Q I , Q O ) = (Z I |A, Z O , γ, Q I , Q O )p(γ, Q I , Q O )dγ = i j,k,l γ A ij Z I ik Z O jl kl p(γ kl )dγ kl = l k γ N kl kl p(γ kl )dγ kl , where N kl = ij A ij Z I ik Z O jl = l k γ N kl +a-1 k,l Γ(1/2 • Q I ) Γ(1/2) Q I dγ kl = Γ(1/2Q I ) Q O Γ(1/2) Q O +Q I l k Γ(N kl + 1/2) Γ(1/2Q I + k N kl )
.

Now, using the fact that log Γ(n + 1) n→∞ ∼ (n + 1/2) log n + n, we obtain:

log γ (Z I |A, Z O , Q I , Q O ) ≈ (n O ,n I )→∞ k,l (N kl log N kl + N kl ) -l Q I -1 2
+ k N kl log ( k N kl ) -k,l N kl . ( 2
log γ ( Z I |A, Z O , Q I , Q O ) ≈ (n O ,n I )→∞ log γ ( Z I |A, Z O , Q I , Q O ) -Q I -1 2 l log i,j A ij Z O jl with γkl = i,j Z I ik A ij Z O jl i,j A ij Z O jl Noticing that log i,j A ij Z O jl = log n I + log i,j A ij Z O jl n I = O(log n I ) leads to log γ ( Z I |A, Z O , Q I , Q O ) ≈ (n O ,n I )→∞ log γ ( Z I |A, Z O , Q I , Q O ) - Q I -1 2 Q O log n I .
(2.D.28) Combining Equations (2.D.25), (2.D.26) and (2.D.28) we obtain the given expression.

2.E. Stochastic Block Model for Generalized Multilevel Network

In this section, I propose a generalization of MLVSBM to networks with more than 2 levels and any number of affiliations. The idea is to generalize the hierarchical model of the interactions given the affiliations developed before.

2.E.1. Description of the generative model

Let L bet he number of levels, n l the number of nodes in level l, and Q l the number of blocks in level l, l ∈ {1, . . . , L}. Level L corresponds to the highest level in the hierarchy (the organizational level in a 2 level multilevel network). Let A l be a matrix of size n l × n l+1 such that for all l ∈ {1, . . . , L -1}:

n l+1 j=1 A l ij ∈ {0, 1}, A l ij ≥ 0.
(A l ij ) can be seen as the proportion of time actor i of level l dedicates to actor j of level l + 1. Each row of A l-1,l sums either to 1 if the actor of the row i has one or multiple affiliations or to 0 if it has none.

I define the generative model as follows:

1. Draw Z L , the latent blocks of level L under the following iid distribution:

P(Z L i = q) = π L q , i ∈ {1, . . . , n L }, q ∈ {1, . . . , Q L }. A Stochastic Block Model for the Analysis of Multilevel Networks 2. Draw for each i ∈ {1, . . . , n L-1 }, the latent affiliation W L-1 ∈ {0, 1} n L-1 ,n L +1
that will be used to determine the block memberships for level L -1. For all j ∈ {0, 1, . . . , n L }:

P(W L-1 i = j) = A L-1 ij 3. Draw Z L-1 i
the blocks of level L -1 independently for all i ∈ {1, . . . , n L-1 } with probability:

P(Z L-1 i = q|W L-1 i , Z L ) = Q L r=1 (γ L-1 kr ) j≥1 W L-1 ij Z L jr ,
4. Iterate step 2 and 3 until W 1 et Z 1 are drawn 5. Draw the intra-level link for all (i = j) ∈ {1, . . . , n l } 2 , l ∈ {1, . . . , L} independently under the following distribution:

P(X l ij = x|Z l i , Z l j ) = f l (x; α l Z l i Z l j
).

(2.E.29)

A DAG depicting the the generative model is given in Figure 2.8 The MLVSBM corresponds to the above model with L = 2, A 1,2 with just one 1 per row and f l a Bernoulli, l ∈ {1, 2}.

A 1 Z 1 X 1 A 2 Z 2 X 2 A L-1 Z L-1 X L-1 Z L X L

Dealing with actors with no affiliation

It is possible to extend the model, so that it handles actors with no affiliation, ie. (i, l) : j A l ij = 0. To do so, we add another column to the matrix of affiliation, such that A l i,n l+1 +1 :=

1 j A l ij =0
. Then, each row of the matrix A l sums to one.

We do the same with the mixture parameter γ l , so that it becomes for l ∈ {1, . . . , L-1}, a Q l × Q l+1 + 1 matrix with each column summing to one. The row Q l+1 + 1 of γ l is a probability vector of length Q l , giving the mixture parameter for actor of level l with no affiliation.

Likelihood of the model From now on, we will assume that the levels are undirected. To ease the notations, we will not consider actors with no affiliation on level l < L, but the extension is straightforward.

The likelihood of the model can be written as follows:

L(X; A) = Z W L(X|Z, W)L(Z, W; A)dWdZ = Z W L l=1 L(X l |Z l ) L-1 l=1 L(Z l |W l , Z l+1 )L(W l ; A l )L(Z L )dWdZ,
where:

L(X l |Z l ) = i =j q,r (α l qr ) X l ij Z l iq Z l jr (1 -α l qr ) (1-X l ij )Z l iq Z l jr L(Z l |W l , Z l+1 ) = i q,r γ l qr j≥1 W l ij Z l iq Z l+1 jr L(W l ; A l ) = i,j A l ij W l ij L(Z L ) = i,q π L q Z L iq

2.E.2. Variational inference

As in the SBM and the MLVSBM, this integral is not tractable. To estimate the maximum likelihood, we will rely on a variational EM algorithm. The trick is to use a variational distribution on W l , for all l ∈ {1, . . . , L -1}, to make it then independent on (Z l , Z l+1 ). As A l is already known, there is no need to infer those parameters.

(X; A) ≥ (X; A) -KL(R(Z, W; A) p(Z, W|X; A)) = E R [ (Z, X, W; A)] + H (R(Z, W; A)) =: J (R(Z, W; A)),
where we choose R in a family of factorizable distribution of the type:

R(Z, W; A) = L l=1 n l i=1 R(Z l i ) L-1 l=1 n l i R(W l i ), with E R [Z l iq ] = τ l iq and E R [W l ij ] = ω l ij . A Stochastic Block Model

for the Analysis of Multilevel Networks

The complete expression of the variational bound is the following:

J (R(Z, W; A)) = 1 2 L l=1 i =i q,r τ l iq τ l jr log f l (X l ii , α l qr ) + L-1 l=1 i q τ l iq ( j≥1 r ω l,l+1 ij τ l+1 jr log γ l qr ) + i,q τ L iq log π L q - L l=1 i,k τ l iq log τ l iq
where we choose ω l ij = A l ij for all l ∈ {1, . . . , L-1}, i ∈ {1, . . . , n l }, j ∈ {1, . . . , n l+1 }.

Parameters update

VE-Step

We need 3 different formulae: one for l = 1, the other for l ∈ {2, . . . , L -1} and a last one for l = L. Maximizing the gradient, using Lagrange multiplier to consider the constrain on τ , we obtain the following fixed point equation:

τ l iq ∝ j =i r f l (X l ij , α l qr ) τ l jr × r γ l qr j≥1 A l ij τ l+1 jr 1 l<L × k γ l-1 kq j≥1 A l-1 ji τ l jk 1 l>1 ×π l q 1 l=L ,
hence the variational block membership parameters of level l, depends on the varational block membership parameters of level l -1, l and l + 1.

M-step

The update of α l , l ∈ {1, . . . , L} are the same as the standard SBM or MLVSBM. It depends on the emission distribution, while we obtain new formulae for γ l , l < L and π L . They are the following:

π L q = 1 n L n L i=1 τ L iq γ l qr = n l i=1 n l +1 j=1 τ l iq A l,l+1 ij τ l+1 jq n l i=1 n l +1 j=1 A l,l+1 ij τ l+1 jq if l < L
The multi-affiliation part of this work is implemented in the R package MLVSBM for multilevel networks with 2 levels.

2.F. MLVSBM package Tutorial library(MLVSBM)

The package deals with multilevel networks defined as the junction of two interaction network (adjacency matrices) linked by an affiliation relationship (affiliation matrix). The notations used in the package are the one from the research paper (Chabert-Liddell et al., 2021).

First, we simulate a multilevel network with 100 individuals and 3 clusters of individuals for the lower level; 50 organizations and 3 clusters for the upper level.

The inter-organizational level will have an assortative structure and will be undirected, the inter-individual's one a core-periphery structure and will be directed. Affiliation matrix will be generated by a power law and the dependency between the latent blocks of the two levels will be strong. We can now infer the parameters, blocks and edge probabilities of our network A Stochastic Block Model for the Analysis of Multilevel Networks by using the mlvlsbm_estimate_network() function on an MLVSBM object. It will return the best model for this network as another R6 object of type FitMLVSBM.

fit <-MLVSBM::mlvsbm_estimate_network(my_mlvsbm, nb_cores = 1L) #> #> [START_REF] Abbe | Community detection and the stochastic block model[END_REF] "Infering lower level :" #> [START_REF] Abbe | Community detection and the stochastic block model[END_REF] "# blocks: 3, ICL = -1753.45 !" #> #> [START_REF] Abbe | Community detection and the stochastic block model[END_REF] "Infering upper level :" #> [START_REF] Abbe | Community detection and the stochastic block model[END_REF] "# blocks: 3, ICL = -429.33 !" #> [START_REF] Abbe | Community detection and the stochastic block model[END_REF] "=== # Individual blocks: 3 , # Organizational blocks: 3, ICL : -2161.44===" #> [START_REF] Abbe | Community detection and the stochastic block model[END_REF] "=== # Individual blocks: 3 , # Organizational blocks: 3, ICL : -2161.44===" #> [START_REF] Abbe | Community detection and the stochastic block model[END_REF] "ICL for independent levels : -2182.78" #> [START_REF] Abbe | Community detection and the stochastic block model[END_REF] "ICL for interdependent levels : -2161.44" #> [START_REF] Abbe | Community detection and the stochastic block model[END_REF] "=====Interdependence is detected between the two levels!====="

2.F.1. Generic functions

Generic functions are provided to print, plot, extract the model parameters and predict the existence of a dyad for the fitted network.

2.F.2. Other useful output

Output of the algorithm are stocked in the MLVSBM and FitMLVSBM objects. The MLVSBM object stocks information of the observed or simulated network and a list of all the fitted SBM and MLVSBM models.

> #> #> $pi #> $pi$O #> [1] 0.1499768 0.5496535 0.3003697 #> #> #> $gamma #> [,1] [,2] [,3] #> [1,] 0.09064248 0.19243672 8.692712e-01 #> [2,] 0.72734754 0.03843131 1.307266e-01 #> [3,] 0.18200998 0.76913196 2.105228e-06 fit$Z # The block membership of each nodes #> $I #> I1 I2 I3 I4 I5 I6 I7 I8 I9 I10 I11 I12 I13 I14 I15 I16 I17 I18 I19 I20 #> 1 3 3 1 3 2 1 2 1 3 1 3 3 1 3 3 1 1 3 1 #> I21 I22 I23 I24 I25 I26 I27 I28 I29 I30 I31 I32 I33 I34 I35 I36 I37 I38 I39 I40 #> 1 1 3 1 3 3 1 1 1 1 3 1 2 2 1 3 2 3 3 3 #> I41 I42 I43 I44 I45 I46 I47 I48 I49 I50 I51 I52 I53 I54 I55 I56 I57 I58 I59 I60 #> 2 1 1 1 2 2 1 3 3 1 2 1 3 1 2 2 2 1 3 3 #> #> $O #> O1 O2 O3 O4 O5 O6 O7 O8 O9 O10 O11 O12 O13 O14 O15 O16 O17 O18 O19 O20 #> 3 2 2 2 1 2 1 1 3 2 3 3 3 2 2 2 2 3 2 2 #> O21 O22 O23 O24 O25 O26 O27 O28 O29 O30 O31 O32 O33 O34 O35 O36 O37 O38 O39 O40 #> 2 3 2 3 2 2 1 1 1 2 2 3 2 3 2 2 3 2 2 3 fit$vbound # A

2.G.1. Simulation Scenario

In this vignette we are interested in the behavior of our inference algorithm when both level of our multilevel network are hard to infer.

For a standard Stochastic Block Model, a well known result is the detectability threshold when the mesoscale structure is the one of a planted partition [START_REF] Decelle | Asymptotic analysis of the stochastic block model for modular networks and its algorithmic applications[END_REF], i.e. the connectivity parameter matrix has the following shape:

p q q p ,
where p and q are the connection probabilities for respectively an intra-block interaction and an extra-block interaction.

Let define a multilevel network with 120 individuals belonging to one of 2 blocks of individuals and 40 organizations belonging to one of 2 blocks of organizations of equal size on average.

Q <-list(I = 2, O = 2) n <-list(I = 60*Q$I, O = 20*Q$O) pi <-rep(1/Q$O, Q$O) gamma <-.1 * (diag(8, Q$I, Q$O) + 2/Q$I)
Then the detectability threshold for each level is given by: detect_threshold <function(n, q) { polyroot(c(n*q*(n*q-2),-2*n*(n*q+1),n**2 )) } Re(detect_threshold(120, .1)) #> [START_REF] Abbe | Community detection and the stochastic block model[END_REF] 0.0500000 0.1666667 for the inter-individual level and Re(detect_threshold(40, .1)) #> [START_REF] Abbe | Community detection and the stochastic block model[END_REF] 0.02192236 0.22807764 for the inter-organizational level. So we will fix the connectivity parameters a little bit above the detectability threshold in order to get a very challenging inference for a single level SBM and to see how the information in each level of the MLVSBM might help to recover the structure of the other level, and how does it vary with the strength of the inter-level dependence.

g 1 -g 1 -g g .
So the two levels are independent when g = .5 and the block membership of an individual is entirely determine by the block membership of his/her organization when g = 1.

set.seed(42) res_detect_thresh <-tibble() for (g in seq(.5, 1, .05)) { gamma <-matrix(c(g, 1-g, 1-g, g), 2, 2) res <-pbmcapply::pbmclapply

2.G.2. Results

With g, the diagonal entry of the mixture dependency parameter γ, we notice that the greater the interdependence the better the levels are able to help each other in the recovery of the clustering. This is obvious from the beginning for the inter-organizational level which is slightly harder to infer. For the inter-individual we notice a great improvement when g ≥ .9. In all case, the problem is hard so we do not obtain a perfect recovery of the blocks every time.

Introduction 97

Abstract Let a collection of networks consists of a set of networks which do not share nodes but which describe the same kind of interactions observed in different situations or contexts. An hypothesis is that the networks in the collection share a common structure since the nature of the interactions is the same. For example in the case of a collection of food webs collected in different ecosystems, one expects that some groups of species (basal species or apex predators e.g.) with similar patterns of trophic relations could be encountered in all the networks.

We propose to build on the popular stochastic block model (SBM) to identify the common structure in the collection. The SBM is a probabilistic model that assumes the existence of latent variables representing the groups of nodes (blocks) of the network and the parameters of which provide a succinct description of the structure of the network at the mesoscopic scale. We call colSBM our extension of the SBM to a joint modeling of a collection of networks. The networks in the collection are assumed to be independent realizations of different SBMs, which share -through common parameters-the same connectivity structure, possibly up to the block proportions and/or a density factor.

The model parameters are estimated and the latent blocks are retrieved using a variational EM algorithm. The existence of a good compromise between the mesoscale structures of these networks is not guaranteed. We use an ad-hoc criterion, based on the integrated classification likelihood to select the number of blocks and to evaluate the adequacy of the consensus found between the structures of the different networks. This criterion can also be used to cluster networks on the basis of their connectivity structures. It thus provides a partition of the collection into subsets of structurally homogeneous networks. An application to a collection of three stream food webs reveals the homogeneity of their structures and provides a more detailed structure of the smaller networks. Finally, we demonstrate how 67 food webs can be clustered and thus described by a small number of connectivity structures.

Introduction

Context For a long time the statistical analysis of network data has focused on analyzing a single network at a time. This could be done by looking at local or global topological features, or by setting a probabilistic model inferred from the network [START_REF] Kolaczyk | Statistical Analysis of Network Data: Methods and Models[END_REF]. When several networks describing the same kind of interactions are available, a natural question is to assess to what extent they are similar or different.

As network data are complex by nature, this comparison of different networks is not an easy task and has mainly focused on comparing statistical topological features on the local, global or mesoscale levels (see Donnat and Holmes, 2018, for a review of graph distances).

In this paper, we focus on the mesoscale structure of the networks by assuming that the nodes can be clustered into groups on the basis of their connectivity pattern [START_REF] White | Social structure from multiple networks. i. blockmodels of roles and positions[END_REF]. We assume that the considered networks have no nodes in common and that the nodes of different networks are not linked as it may be the case Joint inference of a collection of networks in multilayer networks (Kivelä et Our contribution Thus, we propose to jointly model a collection of networks by extending the SBM. We assume that the networks are independent realizations of SBMs that share common parameters. The natural and interesting consequence is the correspondence between the blocks of the different networks. The proposed model called colSBM comes with a few variants, the simplest one assumes that the parameters of the SBMs are identical leading to a collection of i.i.d. networks. As this assumption might be too restrictive for real networks, we introduce two relaxations on this assumption. The first one is to allow the distribution of the block memberships to vary between networks and even to allow some networks to not populate certain blocks. This enables to model a collection of networks where the structure of certain networks is encompassed in the structure of other networks. The second mechanism is to allow networks to have the same structure up to a density parameter. This is particularly useful to model networks with different sampling efforts as it has a direct impact on the density of ecological networks [START_REF] Blüthgen | Measuring specialization in species interaction networks[END_REF]. The inference of the block memberships, the model parameters and the model selection are done through an ad-hoc version of classic tools when inferring SBM, namely a Variational EM algorithm for the inference and an adaptation of the integrated classification likelihood (ICL) criterion for the model selection [START_REF] Daudin | A mixture model for random graphs[END_REF].

The interest of the model is then two-folds, the first one is to find a common connectivity pattern which explains the structure of the different networks in the collection and to assess via model selection whether these structures is a reasonable fit for the collection. As a by-product, it allows a fine analysis of the role structure of the different nodes in the networks. In social/ecological networks, individuals/species

Introduction 99

with the same block membership play the same social/ecological role in its system [START_REF] White | Social structure from multiple networks. i. blockmodels of roles and positions[END_REF][START_REF] Allesina | Food web models: a plea for groups[END_REF]. By sharing the blocks between the networks, colSBM allows to recover sets of nodes which play the same structural roles in different networks. The second one is to provide a partition of the collection of networks into groups of structurally homogeneous networks. will have some practical implications (Michalska-Smith and Allesina, 2019).

As a side effect, by modeling these networks together, provided that the networks have common connectivity patterns, we can use the information of certain networks to recover noisy information from other networks by improving the prediction of missing links [START_REF] Clauset | Hierarchical structure and the prediction of missing links in networks[END_REF]. Hence colSBM has a stabilizing effects on the block-clustering of the nodes of the networks and might give a block membership that is closer to the one of the full real network than just a single SBM as this will be shown in the numerical studies and application. Outline Section 3.2 recalls the definition of the Stochastic Block Model. We motivate our new approach by inferring it independently on a collection of food webs.

Related work

Then in Section 3.3, we present the different colSBM s. The likelihood expression is provided in Section 3.4, together with some identifiability conditions. We develop the methodology for the parameter estimation in Section 3.5 and for model selection Joint inference of a collection of networks in Section 3.6. Section 3.7 deals with network clustering. After some numerical studies to demonstrate the efficiency of our inference procedure and the pertinence of our model selection criterion in Section 3.8, we deal with two applications on food webs in Section 3.9. First, we compare the structures of 3 networks and show the information transfer between these networks. Second, we seek a partition of a collection of 67 networks. The technical details are provided in appendix sections.

Data Motivation and the Stochastic Block Model

Consider a collection of M independent networks where each network indexed by m involves its own n m nodes. The networks are encoded into their adjacency matrices (X m ) m∈{1,...,M } such that: ∀m ∈ {1, . . . , M }, ∀(i = j) ∈ {1, . . . , n m } 2 , X m ij = 0 if no interaction is observed between species i and j of network m X m ij = 0 otherwise.

If the networks represent binary interactions then X m ij ∈ K = {0, 1}, ∀(m, i, j); if the interactions are weighted such as counts, then X m ij ∈ K = N. Moreover, all the networks encompass the same type of interactions (binary, count. . . ) and no self-interaction is considered. Besides, for the sake of simplicity, we assume that all the networks are directed. The extension to undirected networks i.e. such that X m ij = X m ji for any i = j is straightforward. X = (X 1 , . . . , X m ) denotes the collection of adjacency matrices.

A first ecological example: three stream food webs As a first example, we consider the collection of three stream food webs from [START_REF] Thompson | Impacts on stream food webs of native and exotic forest: An intercontinental comparison[END_REF]. The three networks collected respectively in Martins (Maine USA), Cooper and Herlzier (North-Carolina, USA) involve respectively 105, 58 and 71 species resulting in 343, 126 and 148 binary edges respectively. Classically, the food web edges represent directed trophic links showing the energy flow ie. X m ij = 1 if species j preys on species i, with no reciprocal interactions. When aiming at unraveling the structure of these networks the Stochastic Block Model (SBM) is an interesting tool which has proven its high flexibility by encompassing a large variety of structures (see [START_REF] Allesina | Food web models: a plea for groups[END_REF], for the particular case of food webs). When dealing with three networks, the standard strategy that we describe below, is to fit separately one SBM per network.

Separate SBM (sepSBM)

The SBM introduces clusters of nodes and assumes that the interaction between two nodes is driven by the clusters the nodes belong to. More precisely, for network m, let the n m nodes be divided into Q m clusters. Let Collection

Data Motivation and the Stochastic Block Model 101

Z m = (Z m i , . . . , Z m nm ) be independent latent random variables such that Z m i = q if node i of network m belongs to cluster q with q ∈ {1, . . . , Q m } and

P (Z m i = q) = π m q (3.1)
where π m q > 0 and Qm q=1 π m q = 1. Given the latent variables Z m , the X m ij 's are assumed to be independent and distributed as

X m ij |Z m i = q, Z m j = r ∼ F(•; α m qr ), (3.2)
where F is referred to as the emission distribution. F is the Bernoulli distribution for binary interactions, and the Poisson distribution for weighted interactions such as counts. Let f be the density of the emission distribution, then:

log f (X m ij ; α m qr ) =    X m ij log α m qr + (1 -X m ij ) log 1 -α m qr for Bernoulli emission -α m qr + X m ij log α m qr -log(X ij !)
for Poisson emission .

(3.3) Equations (3.1), (3.2) and (3.3) define the SBM model and we will now use the following short notation:

X m ∼ F-SBM nm (Q m , π m , α m ). (sep-SBM )
where F encodes the emission distribution, n m is the number of nodes, Q m is the number of blocks and π m = (π m q ) q=1,...,Qm is the vector of their proportions. The Q × Q matrix α m = α m qr q,r=1,...,Qm denotes the connection parameters i.e. the parameters of the emission distribution. Moreover, α m qr ∈ A F where A F = (0, 1) (resp. A F = R * + ) for the Bernoulli (resp. Poisson) emission distribution. In the sep-SBM model, each network m is modeled independently with its own parameters (π m , α m ).

Application to the three stream food webs

We fit the sepSBM on the 3 stream food webs, respectively referred to as Martins, Cooper and Herlzier. To do so, we use the sbm R-package (Chiquet et al., 2021; Leger et al., 2020) on each network, which implements a variational version of the EM algorithm to estimate the parameters and selects the number of clusters Q m using a penalized likelihood criterion ICL. These inference tools will be recalled hereafter.

We obtain respectively Q 1 = 5 blocks for Martins, Q 2 = 3 blocks for Cooper and Q 3 = 4 blocks for Herlzier. The adjacency matrices of the food webs reordered by block membership are plotted in Figure 3.1. Each food web is composed of 2 blocks of basal species (the 2 bottom blocks). For Cooper, the higher trophic levels are grouped together in the same block, as the lack of statistical power does not allow refinement of the species clustering. For Herlzier the higher trophic level is separated into 2 blocks mainly determined on how much they prey on the less preyed basal block. Martins has a separation into 3 blocks, the third one is a medium trophic level, which preys on basal species and is highly preyed on by species of the first Joint inference of a collection of networks block. The first two blocks are made up of higher trophic level species, with the last two blocks being much less connected than the first.

As can be seen in Figure 3.1, the connectivity structures of these three networks seem to have a lot of similarities. To explore further this aspect, the following section is dedicated to the presentation of several colSBM models assuming common structures among the networks of a given collection.

Joint Modeling of a Collection of Networks

We now present a set of probabilistic models designed to introduce structure consensus into a collection of networks of interest. For ease of notation, we develop the models for directed networks; extensions to the undirected cases are straightforward. Note that the networks (X m ) m=1,...,M are always assumed to be independent random objects. A summary of the various models is provided in Table 3.1, from the most to the less constrained model

A collection of i.i.d. SBM

The first model we propose is the most constrained one and assumes that the networks are independent realizations of the same Q-blocks SBM model with identical parameters. The so-called iid-colSBM states that:

X m ∼ F-SBM nm (Q, π, α), ∀m = 1, . . . M, (iid-colSBM )
where ∀(q, r) ∈ {1, . . . , Q} 2 , α qr ∈ A F , π q ∈]0, 1] and Q q=1 π q = 1. The model involves (Q-1)+Q 2 parameters, the first term corresponding to the block proportions and the second term to the connection parameters.

Collection

Joint Modeling of a Collection of Networks 103

However, assuming that the blocks are represented in the same proportions in each network is a strong assumption that may lead to the model being of little practical use. The following model relaxes this assumption.

A collection of networks with varying block sizes

π-colSBM assumes that the networks share a common connectivity structure encoded in α, but that the proportions of the blocks are specific to each network. Moreover, by allowing some block proportions to be null, the model encompasses situations where some blocks may not be represented in all the realized networks. More precisely, for m ∈ {1, . . . , M }, the X m are independent and

X m ∼ F-SBM nm (Q, π m , α) ∀m = 1, . . . M. (π-colSBM )
where α qr ∈ A F . Moreover, we assume that Q q=1 π m q = 1, ∀m ∈ {1, . . . , M } where π m q ∈ [0, 1] and if π m q = 0 then the block q is not represented in network m. In addition, we assume that for any q ∈ {1, . . . , Q}, ∃m ∈ {1, . . . , M } such that π m q > 0, meaning that any block q is represented in at least one network. Let S be the M × Q support matrix such that ∀(m, q)

S mq = 1 π m q >0 . (3.4)
Then, the set of admissible supports is

S Q := S ∈ M M,Q ({0, 1}), M m=1 S mq ≥ 1 ∀q = 1, . . . , Q (3.5)
For a given matrix S, the number of parameters of the π-colSBM model is deduced as follows:

NP(π-colSBM ) = M m=1   Q q=1 S qm -1   + Q q,r=1 1 (S S)qr>0 (3.6)
The first term corresponds to the non-null block proportions in each network. The second quantity accounts for the fact that some blocks may never be represented simultaneously in any network, so the corresponding connection parameters are not useful for defining the model (see the illustration below). The number of parameters is bounded by M (Q -1) + Q 2 , this upper bound corresponding to the case where all the blocks are represented in all the networks, but with varying proportions. In that case, S = 1 1 1 1 0 1 and the number of parameters is (3 -1) + (2 -

Illustration

1) + 3 × 3 = 12.
3. Finally, let us consider two networks with partially imbricated structures. The two networks share block 1 (for instance super predators) but the remaining nodes of each network cannot be considered as equivalent in terms of connectivity:

α =    α 11 α 12 α 13 α 21 α 22 • α 31 • α 33    π 1 = [.25, .75, 0 ] π 2 = [.40, 0 , .60] .
In that case, S = 1 1 0 1 0 1 . Moreover, blocks 2 and 3 never interact because their elements do not belong to the same network and so α 23 and α 32 are not required to define the model. As a consequence, the number of parameters is equal to (2 -1) + (2 -1) + 7 = 9.

A collection of networks with varying density (δ-colSBM )

The iid-colSBM can be relaxed in another direction, assuming that the M networks exhibit similar intra-and inter-blocks connectivity patterns but with different densities. More precisely, let δ m ∈ R be a density parameter for network m. The δ-colSBM is defined as follows:

X m ∼ F-SBM nm (Q, π, δ m α). (δ-colSBM )
with π q > 0, ∀q = 1, . . . , Q, Q q=1 π q = 1. Moreover ∀(m, q, r), δ m α qr ∈ A F and one of the density parameter equal to one (δ 1 = 1) for identifiability purpose. This model mimics different intensity of connections between networks. δ-colSBM involves NP(δ-colSBM ) = (Q -1) + Q 2 + (M -1) parameters.

Nb of param. iid-colSBM π

m q = π q , π q > 0 α m qr = α qr (Q -1) + Q 2 π-colSBM π m q , π m q ≥ 0 α m qr = α qr ≤ M (Q -1) + Q 2 δ-colSBM π m q = π q , π q > 0 α m qr = δ m α qr (Q -1) + Q 2 + (M -1) δπ-colSBM π m q , π m q ≥ 0 α m qr = δ m α qr ≤ M Q + Q 2 -1 sepSBM π m q , π m q > 0 α m qr M m=1 (Q m -1) + Q 2 m
Table 3.1 -Summary of the various models defined in Section 3.3. The last line corresponds to modeling separately each network as presented in Section 3.2.

Collection of networks with varying block sizes and density (δπ-colSBM )

Finally, we propose to mix the models π-colSBM and δ-colSBM to obtain a more complex one which allows each network to have its own block proportions π m as well as a specific scale density parameter δ m . Then, the (X m ) m∈{1,...,M } are independent and

X m ∼ F-SBM nm (Q, π m , δ m α), (δπ-colSBM )
where ∀(m, q, r), δ m α qr ∈ A F , δ 1 = 1, π m q ≥ 0 and Q q=1 π m q = 1. The number of parameters is given by

NP(δπ-colSBM ) = NP(π-colSBM ) + M -1, (3.7)
the last term corresponding to the aditional proper density of each network. Note that NP(δπ-colSBM

) ≤ M (Q -1) + Q 2 + M -1 = M Q + Q 2 -1.

Likelihood and identifiability of the models

In this section, we derive the expression of the likelihood of the most complex model δπ-colSBM and provide conditions to ensure the identifiability of the parameters for each of the four models.

Log-likelihood expression

For a given matrix S, let θ S be:

θ S = (π 1 , . . . π M , δ 1 , . . . , δ M , α) = (π, δ, α),
where π m q = 0 for any q such that S mq = 0. Let Z m iq = 1 Z m i =q be the latent variable such that Z m iq = 1 if node i of network m belongs to block q, Z m iq = 0 otherwise. We define Z m = (Z m iq ) i=1 ...,nm,q=1...,Q . Then the log likelihood is:

(X; θ S ) = M m=1 log Z m exp { (X m |Z m ; α, δ) + (Z m ; π)} dZ m , (3.8) Joint inference of a collection of networks where (X m |Z m ; α, δ) = nm i,j=1 i =j (q,r)∈Qm Z m iq Z m jr log f X m ij ; δ m α qr , (Z m ; π) = nm i=1 q∈Qm Z m iq log π m q .
with Q m = {q ∈ {1, . . . , Q}|π m q > 0} and f defined as in Equation 3.3. The loglikelihood functions of the other models can be deduced from this one, setting δ m = 1 for iid-colSBM and π-colSBM and π m = π for iid-colSBM and δ-colSBM with S being a matrix of ones (all blocks are represented in each network).

Identifiability

We aim at giving conditions ensuring the identifiability of the models we propose, in the sense that ∀X, (X; θ) = (X; θ ) implies θ = θ . The proof relies on the identifiability for the standard -SBM model demonstrated by [START_REF] Celisse | Consistency of maximumlikelihood and variational estimators in the stochastic block model[END_REF]. Note that, like any mixture models, all the models are identifiable upto a label switching of the blocks. Properties 3.1.

iid-colSBM The parameters (π, α) are identifiable upto a label switching of the blocks provided 1. ∃m * ∈ {1, . . . , M } : n m * ≥ 2Q

2. (α • π) q = (α • π) r ∀(q, r) ∈ {1, . . . , Q} 2 , q = r δ-colSBM The parameters (π, δ 1 , . . . , δ M , α) are identifiable upto a label switching of the blocks provided

1. ∃m * ∈ {1, . . . , M } : n m * ≥ 2Q 2. δ m * = 1 3. (α • π) q = (α • π) r ∀(q, r) ∈ {1, . . . , Q} 2 , q = r π-colSBM Assume that ∀m = 1, . . . , M, X m ∼ F-SBM nm (Q, π m , α). Let Q m = |Q m | = |{q = 1 . . . , Q, π m q > 0}|
be the number of non empty blocks in network m. Then the parameters (π 1 , . . . , π M , α) are identifiable upto a label switching of the blocks under the following conditions:

1. ∀m ∈ {1, . . . , M } : n m ≥ 2Q m 2. (α • π m ) q = (α • π m ) r for all (q = r) ∈ Q 2 m 3. Each diagonal entry of α is unique δπ-colSBM Assume that ∀m = 1, . . . , M, X m ∼ F-SBM nm (Q, π m , δ m α). Let Q m = |Q m | = |{q = 1 . . . , Q, π m q > 0}|
be the number of non empty blocks in network m. Then the parameters (π 1 , . . . , π M , α, δ 1 , . . . , δ M ) are identifiable upto a label switching of the blocks under the following conditions: 3.5. Variational estimation of the parameters 107

1. ∀m : n m ≥ 2|Q m | 2. δ 1 = 1 For Q ≥ 2: 3. (α • π m ) q = (α • π m ) r for all (q = r) ∈ Q 2 m 4. ∀m ∈ {1, . . . , M }, Q m ≥ 2

Each diagonal entry of α is unique

For Q ≥ 3:

6.
There is no configuration of four indices (q, r, s, t) ∈ {1, . . . , Q} such that q = s, r = t and α qq /α rr = α ss /α tt .

7. ∀m ≥ 2, |Q m ∩ ∪ l:l<m Q l | ≥ 2.

Variational estimation of the parameters

We now tackle the estimation of the parameters θ S ∈ Θ S for a given support matrix S. For ease of reading, the index S is dropped in this section. The likelihood given in Equation (3.8) is not tractable in practice, even for a small collection of networks as it relies on summing over M m=1 |Q m | nm terms. A well-proven approach to handle this problem for the inference of the SBM is to rely on a variational version of the EM algorithm. This is done by maximizing a lower (variational) bound of the log-likelihood of the observed data [START_REF] Daudin | A mixture model for random graphs[END_REF]. The approach is similar for both Bernoulli and Poisson models. More precisely,

(X; θ) = M m=1 (X m ; θ) ≥ M m=1 (X m ; θ) -D KL (R m (Z m ) p(Z m |X m ; θ))
where D KL is the Kullback-Leibler divergence and R m stands for any distribution on Z m and R denotes the product distribution: R = ⊗ M m=1 R m . The last equation can be reformulated as:

(X; θ) ≥ M m=1 E Rm [ (X m , Z m ; θ)] + H(R m (Z m )) =: J (R, θ). (3.9)
where H denotes the entropy of a distribution. Now, if R m for all m ∈ {1, . . . , M } is chosen in the set of fully factorizable distributions and if one sets τ m iq = P Rm (Z m iq = 1) then H(R m (Z m )) is equal to:

H(R m (Z m )) = - nm i=1 q∈Qm τ m iq log τ m iq . ( 3

.10) Joint inference of a collection of networks

Besides, the complete likelihood of network m for the δπ-colSBM marginalized over R m is given by:

E R [ (X m , Z m ; θ)] = nm i,j=1 i =j (q,r)∈Qm τ m iq τ m jr log f (X m ij ; δ m α qr ) + nm i=1 q∈Qm
τ m iq log π m q .

(3.11) Finally, the variational lower bound J (R, θ) := J (τ , θ) is obtained by plugging Equations (3.10) and (3.11) into the right member of Equation (3.9). Note that the lower bound

J (τ , θ) is equal to the log-likelihood if R m (Z m ) = p(Z m |X m ) for all m ∈ {1, . . . , M }.
The variational EM (VEM) algorithm consists in optimizing the lower bound J (τ , θ) with respect to (τ , θ), by iterating two optimization steps with respect to τ and θ respectively, also referred to as VE-step and M-step. The details of each step are specific to the model at stake and are detailed hereafter.

VE-step

At iteration (t) of the VEM algorithm, the VE-step consists in maximizing the lower bound with respect to τ :

τ (t+1) = arg max τ J (τ , θ (t) ).
Note that by doing so, one minimizes the Kullback-Leibler divergences between R m (Z m ) and p(Z m |X m ), and so approximates the true conditional distribution p(Z m |X m ) in the space of fully factorizable probability distributions. The τ m 's can be optimized separately by iterating the following fixed point systems for all m ∈ {1, . . . , M }:

τ m(t+1) iq ∝ π m(t) q nm j=1 j =i r∈Qm f (X m ij ; δ (t) m α (t) qr ) τ m(t+1) jr ∀i = 1, . . . , n m , q ∈ Q m . ( 3.12)
M-Step At iteration (t) of the VEM algorithm, the M-step maximizes the variational bound with respect to the model parameters θ:

θ (t+1) = arg max θ J ( τ (t+1) , θ).
The update depends on the chosen model and the estimations are derived by canceling the gradient of the lower bound. For the sake of simplicity, the iteration index (t) is dropped in the following formulae. The obtained formulae involve the following quantities:

e m qr = nm i,j=1 i =j τ m iq τ m jr X m ij , n m qr = nm i,j=1 i =j τ m iq τ m jr , n m q = nm i=1 τ m iq .
On the one hand, the (π (m) q ) q∈Qm are estimated as

π m q =
n m q n m for π-colSBM and δπ-colSBM , Collection 3.6. Model selection 109 which is the expected proportion of the nodes in each allowed block for network m.

On the other hand,

π q = M m=1 n m q M m=1 n m
for iid-colSBM and δ-colSBM , taking into account all the networks at the same time. The connection parameters α qr of iid-colSBM and π-colSBM are estimated as the ratio of the number of interactions between blocks q and r among all networks over the number of possible interactions: Remark. In the VE-Step, each network can be treated independently, so the computation can be parallelized with ease. Also, it can be more efficient to update only a subset of networks at each step to avoid being stuck in local maxima. So we use a slightly modified VEM algorithm where we just compute the VE-step on one network at a time (the order of which is taken uniformly at random) before updating the corresponding parameters in the M-Step.

α qr = M m=1 e m

Model selection

There are two model selection issues. First, under a fixed colSBM , we aim to choose Q and determine the support matrix S for π-colSBM and δπ-colSBM . This task is tackled in Subsection 3.6.1 by introducing a penalized likelihood criterion. Second, the comparison of the the colSBM models -each one introducing various degrees of consensus between the networks-with the sep-SBM -which assumes that each network has its own structure-is dealt with in Subsection 3.6.2.

Selecting the number of blocks Q

A classical tool to choose the number of blocks in the SBM context is the Integrated Classified Likelihood (ICL) proposed by [START_REF] Biernacki | Assessing a mixture model for clustering with the integrated completed likelihood[END_REF]; [START_REF] Daudin | A mixture model for random graphs[END_REF]. ICL derives from an asymptotic approximation of the marginal complete likelihood m(X, Z) = θ exp{ (X, Z|θ)}p(θ)dθ where the parameters are integrated Joint inference of a collection of networks out against a prior distribution, resulting in a penalized criterion of the form max θ (X, Z; θ) -1 2 pen. In the ICL, the latent variables Z are integrated out against an approximation of p(Z|X, θ) obtained via the variational approximation. This leads to the following expression

ICL = max θ E R τ [ (X, Z; θ)] - 1 2 pen
Using the fact that E Rτ [ (X, Z; θ)] ≈ (X; θ) -H(R τ ), one understands that, as emphasized in the literature, ICL favors well separated blocks by penalizing for the entropy of the clustering. However, in this work, our goal is not only to cluster the nodes into coherent blocks but also to evaluate the similarity of the connectivity patterns between the different networks. As such we would like to authorize models providing clustering that may be more fuzzy by not penalizing for the entropy. This leads to a BIC-like criterion of the form:

BIC-L = max θ E R τ [ (X, Z; θ)] + H(R τ ) - 1 2 pen = max θ J (τ , θ) - 1 2 pen
We now supply the expression of the penalty term for the four models we proposed and discuss possible variations of the criterion.

Selection of Q for iid-colSBM and δ-colSBM

For iid-colSBM and δ-colSBM , the derivation of the penalty is a straightforward extension of the classical SBM model, leading to:

BIC-L(X, Q) = max θ J (τ , θ) - 1 2 [pen π (Q) + pen α (Q) + pen δ (Q)] , ( 3.13)
where

pen π (Q) = (Q -1) log M m=1 n m , pen α (Q) = Q 2 log(N M ), pen δ (Q) = 0 for iid-colSBM (M -1) log (N M ) for δ-colSBM .
where

N M = M m=1 n m (n m -1)
is the number of possible interactions. The first term pen π (Q) corresponds to the clustering part where the Q -1 block proportions have to be estimated from the M m=1 n m nodes. The terms pen α (Q) and pen δ (Q) are linked to the connection parameters. Finally, Q is chosen as:

Q = argmax Q∈{1,...,Qmax} BIC-L(X, Q) .

Selection of Q for π-colSBM and δπ-colSBM

Here, in addition to the choice of Q, the collection of support matrices S is considered. In order to penalize the complexity of the model space, we introduce a prior distribution on S defined as follows. Let us introduce Q m = Q q=1 S mq the number of blocks represented in network m. Assuming independent uniform prior distributions on the (Q m )'s and a uniform prior distribution on S for fixed numbers of blocks Q 1 , . . . , Q M represented in each network, we obtain the following prior distribution on S:

log p Q (S) = -M log(Q) - M m=1 log Q Q m
where Q Qm is the number of choices of Q m non-empty blocks among the Q possible blocks in network m. Now, combining the Laplace asymptotic approximation of the marginal complete likelihood (where the parameters have been integrated out) and introducing the prior distribution on S, we obtain the following penalized criterion:

BIC-L(X, Q) = max S max θ S ∈Θ S J (τ , θ S ) - 1 2 [pen π (Q, S) + pen α (Q, S) + pen δ (Q, S) + pen S (Q)] ,
(3.14) where

pen π (Q, S) = M m=1 (Q m -1) log(n m ), pen α (Q, S) =   Q q,r=1 1 (S S)qr>0   log (N M ) , pen δ (Q, S) = 0 for π-colSBM (M -1) log (N M ) for δπ-colSBM , pen S (Q) = -2 log p Q (S).
Finally, Q is chosen such that:

Q = argmax Q∈{1,...,Qmax} BIC-L(X, Q).
The details about the derivation of this criterion are provided in Appendix 3.B.

Practical model selection

The practical choice of Q and the estimation of its parameters are computationally intensive tasks. Indeed, we should compare all the possible models through the chosen model selection criterion. Furthermore, for each model, the variational EM algorithm should be initialized at a large number of initialization points (due to its sensitivity to the starting point), resulting in an unreasonable computational cost. Instead, we propose to adopt a stepwise strategy, resulting in a faster exploration of the model space, combined with efficient initializations of the variational EM algorithm. The procedure we suggest is given in Algorithm 4 and is implemented in an R-package colSBM available on GitHub and that will be on CRAN soon. For initializing a colSBM with Q blocks, we start from fitting a sep-SBM , then, the Q blocks of the M networks have to be associated. This association can be done in Joint inference of a collection of networks many ways due to label switching within each network which provides us with a lot of possible initializations. Then, the stepwise procedure explores the possible number of blocks by building on the previously fitted models. Note that when fitting the π-colSBM or the δπ-colSBM , the support S has to be determined which is done through an extra-step that consists in thresholding the parameters π m related with the block proportions leading to an exploration over the set S Q .

Algorithm 4: Model selection algorithm

Data: X a collection of networks.

begin initialization -Infer sep-SBM on X, with Q ∈ [Q min , Q max ] -Get Ẑm sep-SBM (Q) -Fit
Q = Q max -1, . . . , Q min do
-Fit colSBM with Q blocks from initializations obtained by merging two blocks in models with Q + 1 blocks if π-δπcolSBM s then -Fit colSBM with S qm = 1 πm q >t for different value of threshold t -Among all fitted models, keep the b fitted models with the highest BIC-L for each Q return Q = arg max BIC-L(X, Q), with the corresponding θ, Z and S for π-colSBM and δπ-colSBM .

Testing common connectivity structure

We can also use a model selection approach to choose which model from the 4 colSBM s and the sep-SBM is the most adapted to the collection. The most interesting comparison is to decide whether a collection of networks share the same connectivity structure by comparing the model selection criteria obtained for a given colSBM model with the one of sep-SBM . We decide that a collection of networks

max Q BIC-L colSBM (X, Q) > M m=1 max Qm BIC-L SBM (X m , Q m ).

Partition of networks according to their mesoscale structure

If the networks in a collection do not have the same connectivity structure, we aim to partition them accordingly. We present hereafter a strategy to perform a clustering of the networks.

Clustering a collection of networks consists in finding a partition G = (M g ) g=1,...,G of {1, . . . , M }. Given G, we set the following model on X:

∀g ∈ {1, . . . , G}, ∀m ∈ M g , X m ∼ F-SBM(Q g , π m , δ m α g ) (3.15)
with δ 1 = 1. Moreover, δ m = 1 for all m for iid-colSBM and π-colSBM s and π m = π g for iid-colSBM and δ-colSBM . In other words, the networks belonging to the subcollection M g share the same mesoscale structure given by a particular colSBM . To any partition G we associate the following score:

Sc(G) = G g=1 max Q g =1,...,Qmax BIC-L((X m ) m∈Mg , Q g ). (3.16)
where BIC-L((X m ) m∈Mg , Q g ) is the BIC-L computed on the M g subcollection of networks. The best partition G is chosen as follows:

G * = argmax G Sc(G). (3.17)
Computing the BIC-L for all the partitions G requires to consider the 2 M -1 nonempty subcollections of the networks M, fit the colSBM s on these subcollections and then combine the associated BIC-L in order to be able to compute the scores (3.17). This can be done exhaustively provided that M is not too large but the computational cost becomes prohibitive as M grows.

To circumvent this point, we propose a less computationally intensive forward strategy, starting from G = ({1, . . . , M }), and then progressively splitting the collection of networks. In order to explore the space of partitions of {1, . . . , M }, we define a dissimilarity measure between any pair of networks (m, m ).

Definition of a dissimilarity measure between networks of a collection

(X m ) m∈M . This relies on the following steps. Joint inference of a collection of networks 1. Infer colSBM on (X m ) m∈M to get coherent clusterings of the nodes encoded in τ m = ( τ m iq ) i=1,...,nm,q=1,..., Q , for any m ∈ M. This step supplies the clusterings of the nodes of each network in terms of mesoscale structure. Note that the inference also supplies the ( δ m ) m∈M , these quantities being set to 1 if we work with the π-colSBM and iid-colSBM .

2. For each network m, compute:

n m qr = nm i,j=1 i =j τ m iq τ m jr , α m qr = nm i,j=1 i =j τ m iq τ m jr X m ij n m qr , π m q = nm i=1 τ m iq n m , δ m = nm i,j=1 i =j X m ij
with the convention that π m q = 0 if q / ∈ Q m and α m qr = 0 if {q, r} ⊂ Q m . These quantities are the separated estimates of the parameters encoding the mesoscale structure for each network, computed from node clusterings obtained by considering all the networks jointly.

3. Then, for any pair of networks (m, m ) ∈ M compute the dissimilarity:

D M (m, m ) = Q (q,r)=1 max π m q , π m q max π m r , π m r α m qr δ m - α m qr δ m 2 . (3.18)
This dissimilarity measure quantifies to what extent the connectivity parameters inferred separately on each network of the pair are different. This is weighted by the size of the blocks and corrected in the case of δ-colSBM and δπ-colSBM by the density parameter. If this dissimilarity measure is large, it means that enforcing the same connectivity patterns by estimating common connectivity parameters for these two networks is not relevant and the networks cannot be considered to be part of the same group.

An algorithm to cluster of the collection of networks Now, we use this dissimilarity to guide the search for the best partition of the collection of networks by using Algorithm 5 which consists in a recursive partitioning of the collection.

G * = {G 1 , G 2 }. if Sc 0 > Sc * then return G else return Clust2Coll (X m ) m∈G 1 ,Clust2Coll (X m ) m∈G 2

Simulation studies

In this section, we perform a large simulation study. The first study aims at testing the ability of the inference method to recover the number of blocks and the parameters for the π-colSBM model. The second study highlights the performances in terms of clustering of networks based on their mesoscale structure.

Efficiency of the inference procedure

Simulation paradigm Let us simulate data under the π-colSBM model with M = 2, n m = 100 and Q = 4. α and π are chosen as:

α = .25 +      3 α 2 α α -α 2 α 2 α -α α α -α α 2 α -α α 2 α 0      , π 1 = σ 1 (.2, .4, .4, 0), π 2 = σ 2 (0, 1 3 , 1 3 , 1 3
).

(3.19) with α taking eight equally spaced values ranging from 0 to 0.24. For each value of α , 30 datasets (X 1 , X 2 ) are simulated, resulting in 8 × 30 = 240 datasets. More precisely, for each dataset, we pick uniformly at random two permutations of {1, . . . , 4} (σ 1 , σ 2 ) with the constraint that σ 1 (4) = σ 2 (1). This ensures that each of the two networks have a non-empty block that is empty in the other one. Then the networks are simulated with Bern-SBM 100 (4, α, π m ) with the previous parameters.

Each network has 2 blocks in common and their connectivity structures encompass a mix of core-periphery, assortative community and disassortative community Joint inference of a collection of networks structures, depending on which 3 of the 4 blocks are selected for each network. α represents the strength of these structures, the larger, the easier it is to tell apart one block from another.

Inference On each simulated dataset, we fit the iid-colSBM , π-colSBM and sep-SBM models. The inference is performed with the VEM algorithm and the BIC-L criterions presented in Sections 3.5 and 3.6.1.

Quality indicators

The assess the quality of the inference, we compute the following set of indicators for each simulated dataset.

• First, for each dataset, we put in competition π-colSBM with sep-SBM and iid-colSBM respectively. To do so, for each dataset, we compute the BIC-L of each model π-colSBM is preferred to sep-SBM (resp. iid-colSBM ) if its BIC-L is greater.

• Secondly, when considering the π-colSBM , we compare Q to its true value (Q = 4).

• For π-colSBM and Q fixed to its true value (Q = 4), we evaluate the quality of recovery of the support matrix S by calculating:

Rec( S, S) = max σ∈S 4

1 {∀q,mSmq= S mσ(q) } (3.20)

the greater the better.

• In order to evaluate the ability to recover the true connectivity parameter in the π-colSBM model, we compare α to its true value for the true number of blocks Q = 4 through:

RMSE( α, α) = min σ∈S 4 1 16 1≤q,r≤4 ( α σ(q)σ(r) -α qr ) 2 , ( 3.21)
the σ being there to correct the possible label switching of the blocks.

• Finally, we judge the quality of our clustering with the Adjusted Rand Index (Hubert and Arabie, 1985, ARI = 0 for a random clustering and 1 for a perfect recovery). For each network, for the π-colSBM , using Q, we compare the block memberships to the real ones by taking the average over the two networks

ARI = 1 2 ARI( Z 1 , Z 1 ) + ARI( Z 2 , Z 2 )
and by computing it on the whole collection of nodes

ARI 1,2 = ARI ( Z 1 , Z 2 ), (Z 1 , Z 2

Results

For the model comparison, when α is small ( α ∈ [0, .04]), the simulation model is close to the Erdős-Rényi network and it is very hard to find any structure beyond the one of a single block. As such, the iid-colSBM and π-colSBM models are equivalent and iid-colSBM is preferred to sep-SBM .

We observe a transition when α = .08 where we become able to recover the true number of blocks Q = 4 and the support of the blocks given the true number of blocks. During this transition, the model selection criterion is about half of the time in favor of sep-SBM i.e. the model with no common connectivity structure between the networks.

From α = .16, we recover the true number of blocks and their support most of the time and the common structure obtained by the π-colSBM is found to be relevant.

Note that when we are able to recover the true number of blocks, we are also able to recover their support almost every time.

For both the estimation of the parameters and the ARIs, the results mainly follow our ability to recover the true number of blocks, with the error of estimation of the parameters slowly decreasing from α = 0.12. ARI goes to 1 a bit faster than ARI 1,2 , denoting our ability to recover faster the real clustering of each network than to match the blocks between the networks. This is directly linked with the detection of the true number of blocks and their support. Indeed, to get ARI 1,2 = 1, we need Rec( S, S) = 1 while the effective block number for each network is of only Q = 3, meaning that even with the wrong selected model we can still reach ARI =

Capacity to distinguish π-colSBM from iid-colSBM

We aim to understand how well we are able to differentiate iid-colSBM from π-colSBM depending on the block proportions. To do so, we fix α as in equation (3.19) with α = 0.16 and set π as follows:

π 1 = 1 4 , 1 4 , 1 4 , 1 4
and

π 2 = σ 1 4 -π , 1 4 - π 2 , 1 4 + π , 1 4 + π 2 ,
with π taking 6 values equally spaced in [0, .20]. σ is a random permutation of the blocks. We simulate 30 different collections for each value of π .

Here again, we put in competition π-colSBM with iid-colSBM and sep-SBM and select a model if its BIC-L the greater than the two other ones. Then, for π-colSBM we compare Q to 4 and evaluate our ability to recover S. The results are provided in Table 3.3.

First notice that, since we chose π 0.25, we do not simulate any empty block. As a consequence, the inference of the model is quite easy and we are able to recover the true number of blocks and the right support for the π-colSBM model almost always. When π = 0, π 1 = π 2 and the model reduces to iid-colSBM . This remark explains why iid-colSBM is preferred to π-colSBM when π < .08. As π increases, π-colSBM gets more and more selected, highlighting our capacity to recover the simulated structure.

Partition of networks

The third simulation experiment aims at illustration our capacity to perform a partition of a collection of networks based on their structure, as presented in Section 3.8.3. and for all m = 2, . . . , 9

Simulation scenario

π m = π 1
for iid-colSBM and δ-colSBM σ m (π 1 ) for π-colSBM and δπ-colSBM where σ m is a permutation of {1, 2, 3} proper to network m and σ(π) = (π σ(i) ) i=1,..., [START_REF] Allesina | Food web models: a plea for groups[END_REF] .

The networks are divided into 3 groups of 3 networks with connectivity parameters as follows: .4]. α as represents a classical assortative community structure, while α cp is a layered core-periphery structure with block 2 acting as a semi-core. Finally, α dis is a disassortative community structure with stronger connections between blocks than within blocks. If = 0, the three matrices are equal and the 9 networks have the same connection structure. Increasing differentiates the 3 clusters of networks.

α as = .3 +    -2 -2 -2 -2 -2 -2    , α cp = .3 +    3 2 2 2 0 2 0 -2    , α dis = .3 +    -2 -2 -2    , with ∈ [.1,
For δ-colSBM an δπ-colSBM , we add density parameters δ 1 = δ 4 = δ 7 = 1, δ 2 = δ 5 = δ 8 = 0.75 and δ 3 = δ 6 = δ 9 = 0.5.

We simulate each of these configurations 30 times. We apply the strategy exposed in Section 3.7 and evaluate the recovery of the simulated network partition.

Results

We assess the quality of our procedure by comparing the obtained classifications of the network collection with the simulated one through the ARI index. As grows we are able to better differentiate the networks and do so almost perfectly on all colSBM setup. Note that Adding complexity slightly deteriorates the results as we recover the partition better for iid-colSBM and π-colSBM s than for δ-colSBM and δπ-colSBM . Joint inference of a collection of networks Orange is for the iid-colSBM , green for the δ-colSBM , purple for the δπ-colSBM and yellow for the π-colSBM .

Finding finer block structures

Finally, we perform a last simulation study in order to illustrate the fact that, for particular configurations, using a colSBM model on a collection of networks favors the transfer of information between networks and allows to find finer block structures on the networks. We consider the core-periphery structure configuration described in Equation (3.22) with = .4. In that case Q = 3.

We simulate a collection of 5 networks. 4 networks are of respective size [START_REF] Kivelä | Multilayer networks[END_REF][START_REF] Kivelä | Multilayer networks[END_REF][START_REF] Martínez | A survey of link prediction in complex networks[END_REF][START_REF] Martínez | A survey of link prediction in complex networks[END_REF]. The last network is either smaller with only 60 nodes in the case of iid-colSBM or has a less marked structure (δ = .5) for the δ-colSBM and δπ-colSBM models.

Our goal is to recover the true connection structure of this last network X 5 . To do so, we compare the results obtained using either a standard single SBM on X 5 , or using the corresponding colSBM inferred with M = 2, 3 and 5 networks. We study Q in the various scenarii. In the simulation experiment, we obtained only Q = 2 or 3. The experiment is repeated 30 times. The results are depicted in Figure 3.3.

For the 4 models of simulation, the simple SBM recovers 2 blocks most of the time. For iidcolSBM , we always recover the 3 blocks while for the other case, we improve the ability to recover the true number of blocks when the quantity of information available from the other networks grows, either by augmenting the number of networks or by augmenting the number of nodes. The number of blocks to be recovered is 3 and the darkest shade corresponds to Q = 3.

Application to Food Webs

In this section, we demonstrate the interest of our models on 2 collections of ecological networks . The first one consists of a collection of 3 stream food webs issued from the dataset of [START_REF] Thompson | Impacts on stream food webs of native and exotic forest: An intercontinental comparison[END_REF] described in Section 3.2 at page 100. We analyze in detail the different structures given by the different models and we show how using networks with some common structure helps the prediction of missing information in the networks.

The second dataset is a collection of 67 networks issued from the Mangal database [START_REF] Vissault | rmangal: An R package to interact with Mangal database[END_REF]. We will use our model to propose a partition of the networks into groups of networks with common mesoscale structures.

Joint analysis of 3 stream food webs

In Section 3. For each model, the basal species are separated into 2 blocks (bottom blue blocks in Figure 3.4), similar to the one obtained with the SBMs. The obtained structure slightly differs as described hereafter.

• iid-colSBM highlights 5 blocks in total. Block 3 (light green) is a small block of intermediate trophic level species (ones that prey on basal species and are being preyed on by higher trophic levels) with some within block predation. The higher trophic level is divided into 2 more blocks, block 2 (dark green) only preys on the 2 basal blocks, while block 1 (pink) preys on the intermediate block 3 level but only on the most connected basal species block.

• π-colSBM leads to only 4 blocks, with blocks 1 and 2 corresponding to the top and intermediate trophic levels. There are no empty blocks and the block proportions are still quite homogeneous, with block 2 grossly corresponding to block 1 and 2 of iid-colSBM , rendering the flexibility of the π-colSBM of little use compared to the iid-colSBM on this collection.

• With δ-colSBM , the species are clustered into 6 blocks and the networks have different estimated density parameters: δ ≈ (1, 1.4, 1.6). Block 1 (red) corresponds to the top trophic levels, with blocks 2, 3 and 4 being intermediate levels. Block 4 (light green) is a well connected group with both block 1 and the basal species blocks. Block 2 (pink) is huge and only preys on block 6 while block 3 (dark green) is a small group of species that preys on both basal species blocks.

• Finally, δπ-colSBM clusters the species into 5 blocks with more heterogeneous block proportions and the networks have different estimated density parameters: δ ≈ (1, 1.1, 1.5). Block 1 (pink) is empty on network 2 (Herlzier) and very small on network 1 (Cooper), it corresponds to a block of high trophic level species with within blocks predation, it is well connected to block 3 (light green, intermediate trophic level species) and 5 (dark blue, well connected basal species). Block 2 is of much larger size (especially for network Herlzier) and preys on the same blocks than block 1 but with lower probability for block 3.

Remark. On this collection, the entropy of the clustering is much lower on π-colSBM and δπ-colSBM than on iid-colSBM and δ-colSBM . In these models, to ensure homogeneous block proportions between networks, some nodes tend to get a fuzzy clustering and sit between several blocks (the variational parameters do not concentrate on one block). This phenomenon is taken into account by our model selection criterion which tends to favor models with higher entropy than models with well separated clusters.

Prediction of missing links and dyads Since we have been able to find some common structures between the 3 networks, we now examine if these structures could be used to help recover some information on networks with incomplete information. We proceed as follows: we choose a network m and remove a proportion K ∈ [.1, .8] of For each network, the matrix on the left is the estimated parameter connectivity α, the barplot on the right depicts π (m) . The ordering is done by trophic level from bottom to top and right to left. For (δ-δπ)colSBM s we give δ below the barplot.

• the existing links uniformly at random for the missing link experiment

• or of the existing dyads (both 0 and 1) by encoding them as NA for the missing dyads experiment.

Then, for the missing link experiment, we try to recover where the missing links are among all non existing ones. For the missing dyad experiment, we predict the probability of existence of missing dyads (NA entries). Under the colSBM , the probability of a link between species i and j for network m is predicted by:

p m ij = q,r∈ Qm τ m iq τ m jr δ m α qr .
We resort to the area under the ROC curve to evaluate the capacity of the different models to recover this information. For each value of K, each experiment is repeated 30 times and the results are shown in Figure 3.5.

First, let us notice that these stream food webs networks have a structure that is well explained by an SBM. When there is little information missing (K < .3) the ROC AUC is over 0.9. Besides, with 70% of missing links or dyads, we still predict better than a random guess (ROC AUC ≈ .75). As there is a common structure between the 3 networks, there is a lot of information to be taken from the ones with no missing information. Starting from K ≥ .3, the colSBM s outperform the sep-SBM on both experiments. Even for K = .8, the prediction is still high. About the difference between the colSBM s, for the missing links experiment, as we remove links from one of the network, its density decreases and the models with a density parameters, δ-colSBM and δπ-colSBM have a built-in mechanism that Joint inference of a collection of networks compensates this fact. As a consequence, these models yield to better predictions than iid-colSBM or π-colSBM for large values of K.

Another noteworthy comment on both the NA and missing links experiments is that as K grows, the amount of information on the modified network gets lower. Hence, (π-δπ)colSBM s lacks the statistical power to separate blocks and will empty blocks on this network. This affects our capability to predict the trophic links. On the other hand, (iid-δ)colSBM s will force some separation of the species into blocks, and as the information from the other networks is relevant it still has good prediction performance for large K.

Partition of a collection of 67 predation networks

Now, we consider a collection of 67 predation networks which are all directed networks with more than 30 species, from the Mangal database [START_REF] Vissault | rmangal: An R package to interact with Mangal database[END_REF]. They are issued from 33 datasets each containing between 1 and 10 networks. The number of species ranges from 31 to 106 (3395 in total) by networks; the networks have density ranging from .01 to .32 (14934 total predation links). This dataset is too heterogeneous to find a common structure that will fit well on all the networks. Therefore we propose to use a π-colSBM to look for a partition of the networks into groups sharing common connectivity structures.

We present the obtained network clustering and the connectivity structure of each group in Figure 3.6 as well as a contingency table of the obtained groups with the different datasets of the Mangal database. Our comments on each group follow.

A This group consists of 7 networks and 12 blocks are required to describe this cluster. 5 networks of which are issued from the same dataset (id: 80) and These 5 networks populate the 12 blocks, while the other 2 networks only populate parts of them. The average density is about .18. From the ecological point of view, the blocks can be divided into 3 heterogeneous sets: block 1 to 3 represent the higher trophic levels, block 4 to 8 the intermediate ones and block 9 to 12 the lower ones.

Collection

3.9. Application to Food Webs 125 B This group of 50 networks is the most heterogeneous, it consists mostly of sparse networks, issued from various datasets. Most networks populate only parts of the blocks. The first 3 blocks represent higher trophic levels, with block 1 feeding on almost all the blocks. From block 9 to 11, we observe some symmetry in the connectivity matrix rendering it difficult to order the blocks by trophic order.

C This is a small group of only 3 networks of heterogeneous size (n = [START_REF] Hu | Corrected Bayesian Information Criterion for Stochastic Block Models[END_REF][START_REF] Clauset | Hierarchical structure and the prediction of missing links in networks[END_REF][START_REF] Channarond | Classification and estimation in the Stochastic Blockmodel based on the empirical degrees[END_REF]) but homogeneous density (average .17) issued from two different datasets.

The structure of the 2nd and 3rd networks is encompassed into the 1st one, occupying just blocks 1, 5, 6 and 7 of the 7 blocks. The ecological connectivity structure is clear, a top trophic level on block 1 feeds on all the other blocks. Blocks 2 to 4 are the intermediate level species that only feed on the three last blocks. Block 5 is also an intermediate trophic levels block, while the basal species are divided into the last two blocks depending on there propension to be preyed.

D A small group of 2 homogeneous networks from the same dataset with 50 species each. The 6 block structure follows a kind of stairs shape structure: blocks 1 and 2 are the top trophic species that only feed on block 3 and 4. Block 3 to 5 consist of intermediate trophic level species, with block 3 preying on block 5, and blocks 4 and 5 preying on both blocks 5 and 6.

E

The last group consists of 5 networks containing from 38 to 45 species, four of them are issued from the same dataset (id = 144) while the last one is an outlier of a dataset of 10 networks (id = 157), the others networks from this dataset belonging to group B. The structure consists of 4 blocks, and is a simpler structure of the stair shape structure of group D. Joint inference of a collection of networks

Discussion

In this paper, we proposed a new method to find a common structure and compare different structures of a collection of networks which we do not assume to share common nodes. This method is very general and could be applied to networks sharing common nodes as well, such as temporal or multiplex networks. Starting from our most basic model, -namely the iid-colSBM -we refined it by proposing models allowing for different mixture distributions and even empty blocks (π-colSBM ), models allowing to find common structure for networks of different density (δ-colSBM ) or even models allowing both (δπ-colSBM ). The model selection criterion we derived can be used to select the number of blocks but also to choose which colSBM fits better the data. We also presented a strategy providing a partition of a collection of networks into groups of networks sharing common connectivity patterns.

The idea behind these models is very general and could be extended to other types of networks. In ecology, bipartite and multipartite networks are common and the model extension is straightforward (although some additional modeling choices arise when considering π-colSBM , δ-colSBM or δπ-colSBM ), the main difficulty would then lie in the algorithmic part. The main idea of this article could also be extended to the Degree Corrected SBM (Karrer and Newman, 2011) which is quite used in practice. Finally, the nested version of the SBM proposed by Peixoto (2014b), by allowing a hierarchy on the blocks would be particularly adapted to π-colSBM and δπ-colSBM s.

Finally, we notice during our simulations and applications that the colSBM s allow to find a larger number of blocks compared to the sep-SBM and so lead to a finer resolution of the mesoscale structure of the networks. This resolution limit problem was one of the motivations of Peixoto (2014b) and we believe that this direction should be explored further for collections of networks. Joint inference of a collection of networks

3.A. Proof of identifiability

Proof. [START_REF] Celisse | Consistency of maximumlikelihood and variational estimators in the stochastic block model[END_REF] states that the parameters (π m , α m ) of a SBM nm (Q m , π m , α m ) are identifiable upto label switching of the blocks from a single observed network X m provided

1. n m > 2Q m 2. (α m • π m ) q = (α m • π m ) r for all (q = r) ∈ {1, . . . , Q m } 2
From this result, we prove the identifiability of our colSBM s.

iid-colSBM Under this model, for all m = 1, . . . M , X m ∼ SBM nm (Q, π, α). As a consequence, assuming that ∃m * : n m * ≥ 2Q, we obtain the identifibaility of α and π [START_REF] Celisse | Consistency of maximumlikelihood and variational estimators in the stochastic block model[END_REF], provided that (α•π) q = (α•π) r for all (q = r) ∈ {1, . . . , Q} 2 .

δ-colSBM Under this model, for all

m = 1 . . . , M , X m ∼ SBM nm (Q, π, δ m α).
Assuming that ∃m * : n m * ≥ 2Q and δ m * = 1, we apply the theorem of Celisse et al.

(2012) and obtain the identifiability of α and π under the condition (α•π) q = (α•π) r for all (q = r) ∈ {1, . . . , Q} 2 . Now, for any m = m * , by definition of the SBM model,

E[X m ij ] = δ m π απ,
which proves that δ m is identifiable.

π-colSBM Note that under π-colSBM , we have

X m ∼ F-SBM nm (Q m , π m , α m )
where π m is a vector of non-null proportions of length Q m and α m is the restriction of α to Q m . Under assumptions 1 and 2, applying the theorem of Celisse et al.

(2012) on the distribution of X m , we obtain the identifiability of the parameters π m and α m . However, the identifibaility of each π m and α m is established up to a label switching of the blocks in each network. We now have to find a coherent reordering between the networks and the null block proportions in each network.

We are know able to build the complete matrix α using the α m . First we fill the diagonal of α which is composed of (diag( α m )) m=1,...,M , taking the unique values and sorting them by increasing order, such that α 11 < α 22 < • • • < α QQ . This task is possible because of Assumption 3. Now we get back to π m and reorganize them to match with α. For any m we define φ m : {1, . . . , Q m } → {1, . . . , Q} such that α φm(q),φm(q) = α m qq . With the (φ m ) we are able to fullffil the rest of α as: α φm(q)φm(r) = α m qr for all (q, r) ∈ {1, . . . , Q m } 2 . Finally, we define π m a vector of size Q such that:

π m q = 0 ∀q ∈ {1, . . . , Q}\φ m ({1, . . . , Q m }) π m φ -1 m (q) ∀q ∈ φ m ({1, . . . , Q m }) Collection 3.A. Proof of identifiability 129
δπ-colSBM We now consider the model where

X m ∼ F-SBM nm (Q, π m , δ m α) (3.22)
We set the following conditions.

1. ∀m = 1, . . . M, : n m ≥ 2Q m 2. δ 1 = 1 For Q ≥ 2: 3. (α • π m ) q = (α • π m ) r for all (q = r) ∈ Q 2 m 4. ∀m ∈ {1, . . . , M }, Q m ≥ 2 5. Each diagonal entry of α is unique For Q ≥ 3:
6. There is no configuration of four indices (q, r, s, t) ∈ {1, . . . , Q} such that q = s, r = t and α qq /α rr = α ss /α tt .

7. ∀m ≥ 2, |Q m ∩ ∪ l:l<m Q l | ≥ 2.
Like in model π-colSBM , Equation (3.22) implies that marginally,

X m ∼ F-SBM nm (Q m , π m , α m )
where α m = δ m (α qr ) q,r∈Qm .

Applying Celisse et al. (2012) on the distribution of X m , we obtain the identifiability of the parameters π m and α m (Assumptions 1 and 3). We know have to use the label switching to make the sructures of the networks match and to take into account the empty blocks. We separate the cases Q = 2 and Q > 3.

• For Q = 2, we do not allow empty clusters (Assumption 4, Q m ≥ 2) so α m = δ m α and π m = π m . Using the fact that δ 1 = 1 (Assumption 2), we identify π 1 and α. Since we know that the diagonal entries of α are unique (Assumption 5), α can be chosen such that α 11 > α 22 , thus provided we order well the blocks in each network (with strictly increasing intro block density) we identify the π m uniquely and not up to label switching.

• For Q ≥ 3, for each m ∈ {1, . . . , M }, by Assumptions 1 and 3 and using the marginal distributions, we are able to identify α m and π m .

Using the fact that δ 1 = 1 (Assumption 2) and the fact that the entries of the diagonal of α are unique, we can do as π-colSBM and identify π 1 and α qr , for any q, r ∈ Q 1

Then for m = 2, up to a relabelling of the blocks in α 2 , we can define δ 2 = α 2 11 /α 11 = α 2 22 /α 22 since there are at least two blocks in network m = 2 that correspond to two blocks already identified in the first network by Assumption 7. We need to prove this parameter δ 2 is uniquely defined. Assume that there exists a permutation φ on {1, . . . , M } such that a similar identification occurs. Then we will observe 2) /α 22 with φ such that φ(1) = 1 or φ(2) = 2, which Joint inference of a collection of networks

δ 2 = α 2 φ(1)φ(1) /α 11 = α2 φ(2)φ(
implies that α 11 / α φ(1)φ(1) = α 22 / α φ(2)φ(2)
. This is in contradiction with Assumption 6. Therefore, δ 2 = δ 2 . We can then identify the blocks in network m = 2 by matching α qq /δ with the α qq already identified. The ones that does not match complete the matrix α. The process is iterated with networks m = 3, . . . , M . Once the matrix α and the parameters in δ are identified, injections from {1, . . . , Q m } → {1, . . . , Q} corresponding to the matching of the blocks provide the π m .

3.B. Details of the Model Selection when Allowing for Empty Blocks

For π-colSBM and δπ-colSBM , the model is decribed by its support S. We can compute the likelihood for a given support. We recall that θ S = {α S , δ, π S } are the parameters restricted to their support. Then for the model represented by S, the complete likelihood is given by:

p(X, Z|S) = θ S p(X, Z|θ S , S)p(θ S )d(θ S ) = (α S ,
where we assumed the prior on the emission parameters and the mixture parameters to be independent.

The restriction of the parameter space to the one associated with the support S is needed. Otherwise, some parameters would not be defined or would lie on the boundary of the parameters space, and the following asymptotic derivation would not be properly defined. We use a BIC approximation on B1 where we rewrite:

p(X|Z, S) = (α S ,δ) M m=1 p(X m |Z m , α S , δ, S) p(α S , δ)d(α S , δ) = max (α S ,δ) exp M m=1 (X m |Z m ; α S , δ, S) - 1 2 (ν(α S , δ)) log( m n m (n m -1)) + O(1) , where ν(α S , δ) = ν(α S ) = Q q,r=1 1 (S S)qr>0 (number of free parameters in α S ) in a π-colSBM , ν(α S , δ) = ν(α S ) + M -1 in a δπ-colSBM .
p(Z|S) = m∈M π m S p(Z m |π m S )p(π m S )d(π m S ) = max π S exp M m=1 (Z m ; π m S ) - Q m -1 2 log(n m ) + O(1)
.

Then, we input B1 and B2 into Equation (3.23) to obtain:

log p(X, Z|S) ≈ max θ S (X, Z; θ|S) - 1 2 pen π (Q, S) + pen α (Q, S) + pen δ (Q, S) ,
(3.24) with the penalty terms as given in the main text.

As Z is unknown we replace each Z m iq by the variational parameters τ m iq which maximizes the variational bound for a given support S. Then, we add the entropy of the variational distribution H( R(Z)) to Equation (3.24). This leads to the variational bound of Equation (3.9), as

max θ S J (τ , θ S ) = max θ S (X, E R [Z]; θ S ) + H( R(Z)),
which we recall is a surrogate of the log-likelihood of the observed data. We define

BIC-L(X, Q, S) = max θ S J (τ , θ|S) - 1 2 pen π (Q, S) + pen α (Q, S) + pen δ (Q, S)
which is a penalized likelihood criterion when the support S is known. Finally to obtain the criterion BIC-L(X, Q) for π-colSBM and δπ-colSBM , we need to penalize for the size of the space of possible models that depends on the support S.

For a given Q corresponding to the number of different blocks in the collection of network X, we set the prior on S decomposed as the product of uniform priors on the numbers of blocks (between 1 and Q) actually represented in each network and uniform priors for the choice of these Q m blocks among the Q possible blocks (Q m is the number of blocks that are represented in network m):

p Q (S) = p Q (Q 1 , . . . , Q M ) • p Q (S|Q 1 , . . . , Q M ) = 1 Q M • M m=1 1 Q Q m .
The prior is given on the space S Q of admissible support.

Using a BIC approximation under a concentration assumption on the correct support, we derive

log p(X, Z|Q) = log S p(X, Z|S, Q)p Q (S)dS ≈ log S exp BIC-L(X, Q, S)p Q (S) dS ≈ max S∈S Q BIC-L(X, Q, S) -log p Q (S) .
Thus, by denoting pen S (Q) = -2 log p Q (S) in the equation above, we obtain the expression of BIC-L(X, Q) given in Equation (3.14). Joint inference of a collection of networks

3.C. Partition of Food Webs with δcolSBM

We present the partition of networks and the connectivity structure of each group obtained by fitting a δcolSBM with Poisson distribution and using the binary tree partition method in Figure 3.7 as well as a contingency table of the obtained group with the different dataset of the Mangal database. There are 3 groups, with group A, B being closer in terms of connectivity structure than group C. The blocks are ordered to minimize the upper diagonal interactions. Comments on each groups follow:

A A group of 8 networks, 5 being networks with 78 species issued from the same database (id 58, stream food webs) and the 3 others being smaller networks.

The structure is composed of 11 blocks, the top trophic level does not prey on the bottom 5 ones. Most of the blocks have within blocks interactions.

B A group of 28 networks of various sizes issued from a lot of different databases.

The connectivity matrix has a kind of L-shape. 2 blocks, containing about a quarter of the species, are preyed on by the 4 other blocks. The top two blocks feed on all the other blocks, differing only in intensity.

C A group of 31 networks with a more "stair"-shape structure. The top trophic blocks feed on medium's ones with high intensity but not so much on the lower ones. 10 of these networks are New Zealand stream food webs issued from the same database (id 157).

3.D. Analyze of advice networks

3.D.1. Presentation of the advice networks

In this section, we consider 4 advice networks with binary and directed interactions. In order to make comparison with the different structures, we introduce the following indices which can be computed directly from the SBM parameters for F a Bernoulli distribution:

• Modularity: The propensity of the nodes to interact with nodes from the same Joint inference of a collection of networks block. The higher the more modular:

Mod(F-SBM n (Q, α, π)) = Q q=1 (a qq -( Q r=1 a qr )( Q r=1 a rq )),
where a qr = ( πqαqrπr q,r παπ ) is the the proportion of total interactions being between blocks q and r.

• Reciprocity: The symmetry in the block structure. How close are α qr from α rq . The higher the more reciprocal the network:

Rec(F-SBM n (Q, α, π)) = 1 - 1 2 Q q,r=1 |a qr -a rq | ∈ [0, 1].
• Nestedness: High expected degree nodes connect to high expected degree nodes. A smooth version of core-periphery. The higher the most nested. 1 corresponds to an Expected Degree Distribution (EDD) model.

Nes(F-SBM n (Q, α, π)) = 1 - 1 2 Q q,r=1 |a qr -b qr | ∈ [0, 1],
where b qr =

( Q q=1 πqαqr)r( Q r=1 αqrπr)q Q q,r=1 ( Q q =1 π q α q r )r( Q r =1 α qr π r )q
is the the proportion of total interactions being between blocks q and r for an EDD model.

We fit a SBM on each of the 4 networks. The adjacency matrices reordered by blocks are depicted in the next pictures as well as a table with the 3 indices described above in Table 3.4. A short analysis follows:

• Judges: A structure with 6 blocks of heterogeneous size, with a clear asymmetry in the block connections (low reciprocity index of .371). In particular, block 5 has much higher average indegree than outdegree. The within blocks connections are not very strong, implying a low modularity. It is the most nested network structure of the 4 advice networks.

• Lawyers: A structure with 5 blocks, which the first 3 have very strong within block connections, however this is not the case for the last 2 blocks, leading to a medium modularity. Block 5 is a highly asymmetric block. • Priests: A structure with 4 blocks with a core of 2 blocks and a periphery with assortative community structures on the 2 other blocks. The structure has high modularity but average nestedness and reciprocity compared to the other networks. • Researchers: A structure with 5 blocks, with a kind of assortative community structure for the first 4 blocks. Block 5 consists in the residual individuals with homogeneous connection pattern with the rest of the researchers. The larger the block, the sparser the connection. The structure is the most reciprocal, modular and the least nested of the 4 networks. Joint inference of a collection of networks is caused by the huge difference in density between the two networks forcing some non-common clusters. Priests and researchers are found to have some common structures on all the models, the best fit being for iid-colSBM , while π-colSBM provides the best model for lawyers and researchers.

On collections where we improved the model selection criterion from separated SBM, we plot the structure obtained by the colSBM with the highest BIC-L. We comment on the change in the clustering corresponding to the old separated SBMs structure and the new colSBM structure.

Lawyers and priests

For those two networks with highly different density, only the δπ-colSBM model improved on the separated SBMs. The lawyers advice network has a structure with 6 blocks which embeds the structure of the priests advice network. The obtained ARI between the separated SBMs and the δπ-colSBM is given by .93 for the lawyers and .72 for the priests. Saying it otherwise, the mesoscale structure of the priests network was slightly modified to agree with a partial structure of the lawyers network. The new structure for the priests network is slightly less modular and more reciprocal than the one obtained by the SBM. The changes for the lawyers network are not significant.

We show in Table 3.6, the indices obtained from the δπ-colSBM model parameters and the one given by computing α and π from the obtained variational parameters of this network.

Lawyers and researchers

On these two networks all of the 4 colSBMs improved over separated SBMs. The model selection criterion for π-colSBM is the highest by a large margin, we examine the results further. Individuals of both networks populate the 6 blocks but with large differences in terms of block proportions. For the lawyers, the proportions are homogeneous, while the researchers are mostly in blocks 5 and 6 (blue blocks), which are the least connected ones. The blocks membership for the researchers is only slightly modified compared to the one obtained by the SBM (ARI = .88), but the memberships for the lawyers has a weak agreement with the one obtained from the SBM (ARI = .27).

The new structure of the lawyers network is more modular, more reciprocal and slightly less nested. As for the structure of the researchers network, it became slightly less reciprocal and modular. This exhibits the compromise in the structure found by the π-colSBM . The indices are shown in Table 3 In order to understand the compromise in the structure done for the two networks, we plot the adjacency matrices reordered by blocks. The mesoscale structure of the researchers network did not change much, being mainly an assortative community structure with decreasing within block connectivity and a very small block more connected to the individuals from other blocks. The memberships of the lawyers were reordered in order for its structure to be more assortative and hence to match the one of the researchers network.

Researchers

Priests and researchers

On these two networks all of the 4 colSBMs improved over separated SBMs. The structures of this pair of networks are the most similar of the collection and the iid-colSBM model has the highest model selection criterion. The new structure is shown in the following matricial view of the colSBM. For the researchers, the clustering agree with the one obtained for the separated SBM (ARI = .82), while this is not the case for the priests (ARI = .31. However the number of blocks differs in this case. The new structure finds a compromise in the reciprocity and nestedness of both networks. But, by doing so, the structures are less modular than the ones obtained with the SBM. The indices are shown in We plot the adjacency matrices reordered by blocks for both of the networks. The two structures are very similar the main differences being the residual blocks being much larger for the priest network and the first block being denser for the researcher network.

3.D.3. Looking for larger collections

When considering 3 networks at a time, all of the colSBMs are able to find common structures for the lawyers-priests-researchers collection. This is further evidence that the judges advice networks has a different structure than the 3 other networks, as no collections involving the judges has a higher BIC-L than separated SBMs. The model selection criteria for collections of 3 and 4 networks are shown in Table 3.9 -BIC-L criterion for collections of 3 and 4 advice networks.

Lawyers, priests and researchers

We plot the π-colSBM for the lawyers-priests-researchers collection of networks, as well as individual adjacency matrices with the newly found clustering. The indices of the obtained structures are given in Table 3.11. We obtain a structure of 6 blocks with block proportions being different for the lawyers compared to the one of the priests and judges. Compared to the one obtained from separated SBMs, the structure for the lawyers is less nested, but much more reciprocal and modular; the structure for the priests is less modular, and slightly more reciprocal, while the structure for the researchers did not change much.

Lawyers

Researchers

Judges, lawyers, priests and researchers

For the whole collection of advice networks, we explain the structure found by π-colSBM , the model selection criterion being very close to the one of separated SBMs. We find a 8 blocks structure, with empty blocks for each network. The judges are present on 6 blocks. When looking at the indices for the structure in Table 3.13, the indices for the judges did not change much, but the structure for the researchers, and the priests to a lesser extent, is less modular and more nested than before. The structure of the researchers network had to change in order to find a good compromise with the other networks, which was not the case for collections with 2 or 3 networks without the judges advice network. Structure of the π-colSBM and the matricial view of the 4 networks reordered by blocks are plotted below.

Clustering networks and choosing the best model to explain the collection

We look for each colSBM for the partition of networks which leads to the best BIC-L. The 4 models agree on making a group with lawyers, priests and researchers advice netwroks, which the structure has already been analyzed for π-colSBM . The judges advice network is on a group of its own with the 6 blocks structure obtained by the SBM.

3.D.4. Using dyad prediction to quantify the link between networks

As we have seen before, some advice networks share common connectivity structures with other advice networks, but not all. To further illustrate this fact, we will try to predict the value of missing dyads between the individuals of a given network, using the information from the other networks. Recall that these networks do not share any individuals and that any improvements in the prediction are due to similar connection patterns between the networks in the collection.

We will plot the ROC AUC of the prediction obtained from an SBM on the researchers and the judges network and the one with δ-colSBM on various collections of networks.

We make the number of missing dyads vary between 10% and 80% (K) of the total number of dyads and simulate 30 times the missing dyads for each value of K. A value of .5 means that the prediction is not better than a uniform one on all missing dyads. The baseline will be the black dots on the figures, which is the prediction obtained by an SBM on a single network (judges or researchers). Information obtained from other networks of the collection improve the prediction of interactions between researchers or judges if it has a higher ROC AUC than the one obtained from the SBM.

Predicting interactions between Researchers

colSBM found common structure between the researchers network and both the priests and the lawyers networks. For small and medium K, collections involving the judges provide poor prediction while the ones involving priests improve the prediction of advice between researchers. When K is higher than .8, the information obtained from the judge network significantly improves significantly the prediction of missing dyads, as almost no structure remains in the researchers network. Joint inference of a collection of networks

Predicting interactions between judges

Improving the prediction of advice between judges with the information coming from other networks is harder than for the researcher when K is small. But the capacity to predict stays good when K becomes larger. Information from priests and lawyerspriest advice networks improve the predictions, while the information coming from the researchers are just noise, providing worst prediction than considering the judges on their own. Among all our experiments the advice networks from the judges exhibit different connection patterns than the 3 other networks, but common connectivity patterns still exist as shown in the prediction section. Priests and researchers advice networks are the most similar. About the lawyers advice network, which is a lot denser than the other ones, it is possible to find another mesoscale structure to explain the connectivity patterns of the network. The new connectivity structure is a good compromise with the one of the researchers and priests advice networks.

Advice networks share common connectivity patterns, which could be grossly described as an assortative community structure with various within block interaction probability, and an asymmetry in the connections of the most connected blocks. For the judges advice network, the assortativity is weaker and the reciprocity in the connection between blocks is much lower. Abstract The robustness of an ecological network quantifies the resilience of the ecosystem it represents to species loss. It corresponds to the proportion of species that are disconnected from the rest of the network when extinctions occur sequentially. Classically, the robustness is calculated for a given network, from the simulation of a large number of extinction sequences. The link between network structure and robustness remains an open question. Setting a joint probabilistic model on the network and the extinction sequences allows analysis of this relation. Bipartite stochastic block models have proven their ability to model bipartite networks e.g. plant-pollinator networks: species are divided into blocks and interaction probabilities are determined by the blocks of membership. Analytical expressions of the expectation and variance of robustness are obtained under this model, for different distributions of primary extinction sequences. The impact of the network structure on the robustness is analyzed through a set of properties and numerical illustrations. The analysis of a collection of bipartite ecological networks allows us to compare the empirical approach to our probabilistic approach, and illustrates the relevance of the latter when it comes to computing the robustness of a partially observed or incompletely sampled network.

Introduction

In response to the rapid evolution of ecosystems due to climate change (habitat losses and species extinctions) on the one hand, and the increasing number of available data sets of ecological interaction networks on the other hand, the study of the robustness of ecological networks to species loss has become an active area of research in the ecological scientific community (see [START_REF] Landi | Complexity and stability of ecological networks: a review of the theory[END_REF], for a review). Given a primary extinction sequence, the influence of these extinctions on the other species is studied by monitoring the proportion of species that get disconnected from the rest of the network [START_REF] Dunne | Network structure and biodiversity loss in food webs: robustness increases with connectance[END_REF].

Bipartite networks are used to represent interactions between two separated sets of species that do not interact within their own set. These interactions may be either mutualistic when the species of both groups benefit from the interactions (such as pollination for plant-pollinator networks or seed-dispersal for plant-frugivore bird networks) or antagonistic when one group of species benefits from the interactions at the expense of the other group of species (e.g. plant-herbivore or host-parasite networks). Robustness is a numeric indicator quantifying the impact of the disappearance of one set of (primary) species on the other (secondary species) under given extinction sequences (see [START_REF] Memmott | Tolerance of pollination networks to species extinctions[END_REF][START_REF] Curtsdotter | Robustness to secondary extinctions: comparing trait-based sequential deletions in static and dynamic food webs[END_REF], for examples of primary extinction sequences). In a few words, the object of interest is the proportion of secondary species that remain connected to other species after a given number of primary species have disappeared. Since this proportion depends on the order in which the species disappear, robustness is defined as the average of these proportions over a large number of primary extinction sequences. The definition of ecological robustness used in this paper is not the only one, in particular the robustness of ecological networks is also studied through dynamic approaches. Among recent developments in the dynamic approach, [START_REF] Song | A guideline to study the feasibility domain of multi-trophic and changing ecological communities[END_REF] are interested in the feasibility domain of ecological communities, i.e. the set of environmental conditions under which all species have positive abundances. [START_REF] Barabás | Sensitivity analysis of coexistence in ecological communities: theory and application[END_REF] estimate extinction risk to small environmental variation through the use of sensitivity analysis while others study the capacity of coexistence of species through the so-called invasion criterion (see [START_REF] Grainger | The invasion criterion: a common currency for ecological research[END_REF], for a review).

Obviously, the robustness defined above is strongly related to the size of the network considered (i.e. the number of species involved or species richness) and to its density (i.e. the number of interactions observed compared to the total number of possible interactions or connectance). To go further, the question arises to what extent the topological properties of a network also influence its robustness. Indeed, observed ecological networks present different topological structures depending on the type of interactions: for example, mutualistic networks are known to have a strong nested structure, while this is not necessarily the case for antagonistic networks [START_REF] Fortuna | Nestedness versus modularity in ecological networks: two sides of the same coin[END_REF][START_REF] Bascompte | The nested assembly of plant-animal mutualistic networks[END_REF]. A key question is to identify the relationship between the ability of a network to withstand species extinctions and its characteristics such as its size and its mesoscale structure.

To that purpose, we propose to assume a parametric probabilistic model for the bipartite network. This model will embed the topological properties of the network in a few number of parameters. Then we propose to study the behavior of the robustness in this framework and in particular the variations of the robustness with respect to the model parameters. More precisely, we focus on the expectation and the variance of the robustness under a network probabilistic model. For some particular probabilistic models and some particular extinction sequences, the relation between the parameters and the expected robustness can be provided in a closed-form, making a fine study of the relation possible.

Furthermore, relying on a probabilistic model which can be adjusted to account for an observation process may enable for correction of the sampling effect on the robustness. Indeed, even though ecological networks are often considered to describe all the possible interactions between species, the sampling may be incomplete [START_REF] Blüthgen | What do interaction network metrics tell us about specialization and biological traits[END_REF] traditionally used in the information or epidemic networks literature. In these fields, the goal is to see how a network stays connected when some nodes are disabled (or on the opposite how epidemics are still able to spread when nodes become immune), the task is tackled by analyzing the size of the different connected components and in particular the existence of a giant connected component (see [START_REF] Newman | Networks[END_REF], chapter 15 and reference therein). In ecology, the key issue is to observe how species get isolated from the rest of the ecosystem. This approach is related to the concept of isolated nodes in a graph [START_REF] Erdős | On the evolution of random graphs[END_REF].

fields during the last decade. While the Erdős-Rényi model [START_REF] Erdős | On the evolution of random graphs[END_REF] assumes that any pair of species has the same probability of interaction, SBMs introduce heterogeneity in the connection behavior. Specifically, in bipartite SBMs, the two sets of nodes are divided into clusters/blocks/groups and the probability that two nodes are connected depends on which blocks the nodes belong to. Depending on the number of blocks, their size, and interaction probabilities (inter-and intra-block), SBMs encompass a wide variety of topologies (such as assortative community or core-periphery) and encode them in a small number of parameters.

Since [START_REF] Allesina | Food web models: a plea for groups[END_REF] (2020) use biSBM to assess the core-periphery structure of plant-pollinator networks. Furthermore, SBMs provide an ecological interpretation in terms of functional groups in the ecosystem: species in the same block interact in a similar way, which means that the exchangeability of species in a block model is related to the concept of ecological equivalence [START_REF] Sander | What can interaction webs tell us about species roles?[END_REF].

To our knowledge, the behavior of the robustness has never been studied in the SBM framework. Some grouping algorithms are used to derive extinction sequences. [START_REF] Cai | The robustness of ecosystems to the species loss of community[END_REF] optimize an objective function to determine communities in the network and then generates primary extinction based on these communities. More generally, some models are used to generate primary extinction sequences, or to model how species of the other functional group react to those extinctions (such as rewiring or cascading, see [START_REF] Bane | Effects of model choice, network structure, and interaction strengths on knockout extinction models of ecological robustness[END_REF]Vizentin-Bugoni et al., 2020, for examples). In an approach more similar to ours, [START_REF] Burgos | Why nestedness in mutualistic networks[END_REF] studied the relationship between nestedness and robustness of mutualistic networks by using the self-organizing network model [START_REF] Medan | Analysis and assembling of network structure in mutualistic systems[END_REF] to generate nested networks and derived analytical expression of the robustness under this model.

The robustness given as a decreasing function and a robustness statistic classically used in ecology are described in Section 4.2. Section 4.3 is dedicated to the introduction of the biSBM, the DCbiSBM and related models for sequential species extinctions. Section 4.4 supplies the expression of the expectation and the variance of the robustness under a biSBM for different distributions of primary extinction sequences. The analytical properties of the expected robustness are given in Section 4.5 together with more general studies to illustrate the impact of the network structure on the robustness. In Section 4.6, we apply our approach on a dataset composed of both mutualistic and antagonistic bipartite networks and compare our results to the classical approach. Finally, on the same dataset, we show how our approach allows us to calculate the expected robustness of partially observed ecological networks.

Robustness of bipartite ecological networks

Robustness aims at measuring the tolerance of a network to species extinctions by quantifying the proportion of remaining species along a species extinction sequence. Formally, let A ∈ {0, 1} nr×nc be the n r × n c incidence matrix of a bipartite network representing ecological interactions between two groups of species of respective sizes n r and n c (such as plant-pollinators or hosts-parasites). Then:

A ij =   
1 if row species i interacts with column species j, 0 otherwise.

Let s be an extinction sequence on the row species: s ∈ S nr where S nr is the symmetric group. The extinctions in row (whose order is given by s) are the primary extinctions. These row extinctions lead to secondary extinctions among the column species if these column species remain isolated after the disappearance of row species. More precisely, a column species j is said to be be extinct after m row primary extinctions if these m primary extinctions caused species j to lose all its connections, or equivalently if after these m primary row extinctions, j has no connections left with the remaining rows, which is equivalent to nr i=m+1 A s(i)j = 0. For a given sequence s and a given number of primary extinctions m, R(A, s, m) is the proportion of remaining column species:

R(A, s, m) = 1 - 1 n c nc j=1 1 { nr i=m+1 A s(i)j =0} . (4.1)
Note that for all m ∈ {0, . . . , n r }, 0 ≤ R(A, s, m) ≤ 1 with R(A, s, n r ) = 0. The robustness function is defined as the expectation of R(A, S, m) against the primary extinction sequences:

m → R S (A, m) = E S [R(A, S, m)] with S ∼ S . (4.2)
where S is a probability distribution on S nr . Equation (4.2) is a weighted summation over the n r ! possible permutations of S nr , which may render the computation intractable. In practice, it is generally approximated by a Monte Carlo integration: Other statistics exist in the literature, such as the median of the robustness function [START_REF] Dunne | Network structure and biodiversity loss in food webs: robustness increases with connectance[END_REF], i.e. the proportion of primary extinctions needed to provoke a secondary extinction on half of the species. However, the statistic (4.4) is widely used in ecology and is mathematically convenient for our purpose.

About the extinction sequence distribution S Several choices for S corresponding to various ecological scenarios are commonly considered in the literature. The first choice is the uniform distribution over S nr (S = U Sn r ), assuming that the species disappear without specific order. For the sake of simplicity, we use U instead of U Sn r .

Distributions S depending on A are suggested in the literature (see [START_REF] Curtsdotter | Robustness to secondary extinctions: comparing trait-based sequential deletions in static and dynamic food webs[END_REF], for examples). Among these approaches, we will focus on sequences depending on the row degree sequences. For any row species i = 1, . . . , n r , let D i = nc j=1 A ij be its degree, i.e. the number of edges involving i. On the one hand, the worst-case scenario in terms of ecological extinctions assumes that the row species with the highest degrees (most connected row species) disappear first. In this case, the species in rows are ordered in decreasing degrees and the primary extinction sequences follow this order; row species of equal degrees disappear in a uniformly distributed order. On the other hand, the generation of primary extinction sequences that first eliminate species of lower degree mimics a more favorable ecological scenario. In these two cases, the support of S is of cardinal k #{i : D i = k}!. Depending on the sequence (D i ) i=1,...,nr , the corresponding R S (A, m) may become tractable or not. If not, a Monte Carlo approximation is used.

Instead of considering a strict monotone ordering of the row degrees, one might relax the constraint and set the probability for a row species to disappear proportional to a function of its degree, as seen in [START_REF] Liu | Node attacks on two-mode networks[END_REF]. This would correspond to sampling without replacement a sequence s where the weights of each species i ∈ {1, . . . , n r } are, for instance given by: This robustness computed for a given A will be referred to as the empirical robustness.

w i ∝ D α i . ( 4

Bipartite Stochastic Block Model and related sequential extinctions 155

In order to understand the variability of the robustness with respect to the network structure we set a probabilistic model on the network A ∼ A θ where the parameters θ embeds the network structure in a small number of parameters and then study the random variable R S (A, m) for various distributions on (S, A). The following section is dedicated to the description of flexible probabilistic models on A and adapted joint distributions on A and S. [START_REF] Govaert | Clustering with block mixture models[END_REF], is a mixture model on the edges adapted to bipartite networks. It relies on a clustering of nodes in rows and a clustering of nodes in columns. The nodes which belong to the same cluster (or equivalently block) are assumed to share the same connectivity profile in the network and the probability of interaction between two nodes depends on the blocks they belong to. More precisely, each of the n r row species is attributed to a block k ∈ {1, . . . , Q r } independently from the other species. Let Z i be such that Z i = k if row species i belongs to block k. The Z i 's are assumed to be independent and identically distributed (i.i.d.) and:

Bipartite Stochastic

P(Z i = k) = π k i ∈ {1, . . . , n r }, (4.7)
with Qr k=1 π k = 1. For j = 1, . . . , n c , let W j be such that W j = q if column species j belongs to block q ∈ {1, . . . , Q c }. The W j 's are assumed to be i.i.d. and:

P(W j = q) = ρ q j ∈ {1, . . . , n c }, (4.8)
with Qc q=1 ρ q = 1. Then, conditionally to their respective latent blocks, the interactions between two species are distributed independently as:

A ij |{Z i = k, W j = q} ∼ B(δ kq ), (4.9)
where B is the Bernoulli distribution and δ kq ∈ (0, 1) for (k, q) ∈ {1, . . . , Q r } × {1, . . . , Q c }. The parameter θ = {ρ q , π k , δ kq } k=1,...,Qr,q=1,...,Qc then encodes the topology of the network. Let n = (n r , n c ) be the numbers of species (richness) in rows and in columns of the network: biSBM (θ, n) denotes the distribution on the networks defined by equations (4.7), (4.8) and (4.9) for a given value of θ. Note that d = k,q π k δ kq ρ q is the expected connection probability for any pair of species (i, j). d will be referred to as the expected density. Remark. A special case among the biSBM distributions is the one where δ kq = d for any k, q , or equivalently -in terms of models on networks-where Q r = 1 and Q c = 1. In that case, all connections occur independently with the same probability d. This biSBM is the bipartite Erdős-Rényi network.

Degree corrected stochastic block models

The degree corrected stochastic block model [START_REF] Karrer | Stochastic blockmodels and community structure in networks[END_REF]) is an extension of the SBM which accounts for the heterogeneity in the degree distribution. This heterogeneity does not only depend on the blocks but also on some parameters related to the nodes themselves. The extension to bipartite network is done in [START_REF] Larremore | Efficiently inferring community structure in bipartite networks[END_REF]. In these models, the distribution on the dyads is a Poisson distribution even if the observed network consists of binary edges. This is a reasonable approximation in the case where the network is large and sparse. However, in ecological interaction networks, this assumption is hardly met. That is why we use a true binary definition of the degree corrected biSBM that we denote by DCbiSBM in the following. On top of the blocks for the nodes in rows and columns given by variables Zs and W s as defined in Equations (4.7) and (4.8), two vector parameters γ r ∈ R nr and γ c ∈ R nc are associated to the nodes and control their degree. The larger γ r,i (resp. γ c,j ) the higher the probability of connection involving species i (resp. j), compared to other species within the same block. Then, Equation (4.9) is replaced with

A ij |{Z i = k, W j = q} ∼ B(1/(1 + exp(-(δ kq + γ r,i + γ c,j ))) , ( 4.10)
with γ r,1 = γ c,1 = 1 for identifiability issues.

We denote by DCbiSBM (θ, γ, n) where γ = (γ r , γ c ), this probabilistic model with a given set of parameters. If there is only one block, i.e. Q r = Q c = 1, this model only accounts for the heterogeneity of degrees and so corresponds to a bipartite version of the expected degree distribution (EDD) model [START_REF] Chung | Connected components in random graphs with given expected degree sequences[END_REF].

Extinction sequence distributions adapted to bipartite Block Models

As described in Section 4.2, classically, the extinction sequences are either distributed uniformly on S nr or conditionally to A. Positing a probabilistic distribution on A leads to a joint distribution on A and S. In the case of a uniform distribution on S: S ∼ U, the joint distribution on (A, S) consists of the product of the distributions for A and S. We will then denote by L θ,n,U and L θ,γ,n,U the corresponding joint distributions when A ∼ biSBM (θ, n) or A ∼ DCbiSBM (θ, γ, n) respectively.

As described in Section 4.2, the extinction sequences may depend on A through its degree distributions. When A follows a probabilistic distribution, such an extinction sequence is defined conditionally on the realization of A. We propose another dependence between A and S through the row clustering variables Zs. More precisely, we consider that species of row block 1 disappear first, then block 2, etc. Formally, let B be the uniform probability on the row species following a given ordering of the blocks, then S|Z ∼ B if:

P(S = s|Z) = 1 Z s(1) ≤•••≤Z s(nr ) #{s : Z s(1) ≤ • • • ≤ Z s(nr) } . (4.11)
The support of B is restricted to Qr k=1 n k ! elements, where n k is the cardinal of block k. Equations (4.7), (4.8), (4.9) and (4.11) define a joint probability distribution on (A, S) such that A and S are independent conditionally to Z. We denote L θ,n,B this joint distribution on (A, S) when A ∼ biSBM (θ, n). Under this joint distribution, if θ is such that δ k+ = Qc q=1 ρ q δ kq is a decreasing (resp. increasing) sequence, then B will generate sequences with an expected decreasing (resp. increasing) sequence of degrees, i.e. with decreasing (resp. decreasing) connectivity. In the following, these extinction sequences will be referred to as block-decreasing (resp. blockincreasing). The blocks may also be used to generate extinctions by ecological traits that correspond to the blocks.

If A ∼ DCbiSBM (θ, γ, n), the extinction sequences are not related to expected degrees anymore but it may still make sense to generate extinction sequences linked to ecological traits.

Moments of the robustness statistic

Studying the distribution of R(A, S, m) or R(A, S) = 1 nr M m=1 R(A, S, m) under the joint distribution of A and S could be done by simulation, using the fact that the biSBM and DCbiSBM are generative models. However, this comes at a computational cost. In this section, we prove that, when (A, S) ∼ L θ,n,U or (A, S) ∼ L θ,n,B the first moments of the robustness are tractable in a closed-form. The proof relies on the exchangeability of the nodes under a biSBM and on the fact that the considered extinction sequences are adapted to this exchangeability. When A follows a DCbiSBM, the nodes are no longer exchangeable because of the parameters γ associated with each node. Although we are able to obtain a closed-form expression, it is not tractable. Therefore, we will rely on a Monte Carlo approximation for summing on the extinction sequences.

We now exhibit explicit expressions of R θ,n,S (m) = E A [R S (A, m)] when (A, S) ∼ L θ,n,U or L θ,n,B and of • Consequently, the robustness statistic is:

V A [R U (A, m))] when A ∼ biSBM (θ, n).

Expectation

R A,S (m) = E A [E S [ R(A, S, m) ]] = E A [ R U (A, m) ] = 1 n r ! s∈Sn r   1 - 1 n c nc j=1 E A 1 nr i=m+1 A s(i)j =0   .
Using the property of exchangeability of the biSBM, we have that, for any permuta-

tion s, E A 1 nr i=m+1 A s(i)j =0 = E A 1 nr i=m+1 A ij =0
. Moreover, introducing the latent variables Z and W we have:

E A 1 nr i=m+1 A ij =0 =
δ k i q )   nr i=m+1 π k i   ρ q = Qc q=1 ρ q k m+1:nr ∈{1,...,Qr} nr -m nr i=m+1 (1 -δ k i q )π k i = Qc q=1 ρ q   Qr k=1 π k (1 -δ kq )   nr-m .
As a consequence,

R θ,n,U (m) = 1 - Qc q=1 ρ q   Qr k=1 π k (1 -δ kq )   nr-m = 1 - Qc q=1 ρ q (1 -δ +q ) nr-m
where δ +q = Qr k=1 π k δ kq . Then, averaging over m leads to:

R θ,n,U = 1 n r nr m=0 R θ,n,U (m) = 1 - 1 n r Qc q=1 ρ q (1 -δ +q ) -(1 -δ +q ) nr+1 δ +q .
Note that, if the network has no specific structure ( In Equation (S-4.19), the summation over the partitions of the n r row species into Q r blocks may be burdensome if n r or Q r are large. In such cases, a Monte Carlo approximation may be used. Among the ecological networks we consider in Section 4.6, only a few of them require this approximation.

δ kq = d or Q r = Q c = 1) then R θ,n,U (m) = 1 -(1 -d) nr-m . Proposition 4.2. Let (A, S) ∼ L θ,n,B , then R θ,n,B (m) = 1 - Qc q=1 ρ q n 1 +•••+n Qr =nr n r ! n 1 ! . . . n Qr ! Qr k=1 π n k k (1 -δ kq ) min + (n k , l≤k n l -m) , ( 4

Variance

We now aim at computing the variance of the robustness V A [R U (A, m)], when A ∼ biSBM (θ, n), thus quantifying the variability of the robustness for a sample of networks sharing the same block models parameters (i.e. the same mesoscale patterns of connectivity). Proposition 4.3. Let A ∼ biSBM (θ, n), η q = 1 -δ +q and η qq = Qr k=1 π k (1δ kq )(1 -δ kq ).

Then:

V A [R U (A, m)] = 1 n c min(2m,nr) l=m m l-m nr-m l-m nr m Qr q=1 ρ q η l q -( Qr q=1 ρ q η m q ) 2 + (n c -1) n c max(2m,nr) l=m m l-m nr-m l-m nr m Qr q,q =1 ρ q ρ q (η q η q ) l-m η 2m-l qq .

The variance of the robustness statistic due to the network variability under a

given biSBM is:

V A [R U (A)] = 1 n 2 r n 2 c n c nr m,m =0 min(m+m ,nr) l=max(m,m ) m l-m nr-m l-m nr m Qr q=1 ρ q η l q -( 1 n r nr m=0 Qr q=1 ρ q η m q ) 2 + 1 n 2 r n 2 c n c (n c -1) nr m,m =0 min(m+m ,nr) l=max(m,m ) m l-m nr-m l-m nr m Qr q,q =1 ρ q ρ q η l-m q η l-m q η m+m -l qq .
The proof is provided in the supplementary material 4.A. The expectations of the robustness under the biSBM given in Proposition 4.1 and 4.2 only rely on the model parameters θ and the number of rows n r , whereas the expression of the variance also involves the number of columns n c . Note that for the block sequences S = B, the calculus is not so simple, but the value could still be estimated by simulations if required.

V A (R U (A)) quantifies the variability of the robustness statistic among a population of networks distributed as biSBM. However, from an ecological point of view, it could also be interesting to quantify the variability of the robustness of a network with respect not only to the network but also to the extinction sequence. This is obtained by computing

V A,S 1 n r nr m=1 R(A, S, m) = V A,S R(A, S)
Remark. This total variance can be reformulated as:

V A,S R(A, S) = E S V A|S (R(A, S)) + V S E A|S (R(A, S) ) = E S V A (R(A, S)) (4.15) = E A V S (R(A, S)) + V A E S (R(A, S) ) (4.16)
because S and A are independent under L θ,n,U and E A|S (R(A, S)) does not depend on S by exchangeability. The total variance can be expressed explicitly for S = U as

V A,S R(A, S) = n c n 2 r n 2 c nr m,m =0 Qr q=1 ρ q η nr-min(m,m ) q - 1 n r Qc q=1 ρ q η q -η nr+1 q δ +q 2 + n c (n c -1) n 2 r n 2 c nr m,m =1 Qr q,q =1 ρ q ρ q η max(m,m )-min(m,m ) q η nr-max(m,

Illustration of the variability of the robustness function

In When the rate of extinction exceeds one of these proportions, the extinctions which were only happening in one block then happen in the other block. Also notice that when S = B ordered by increasing connectivity, some networks still have a robustness of 1 even after a large fraction of primary extinctions has occurred. The robustness for this primary extinction distribution is highly dependent on the degree of the most connected primary species.

Impact of the Network Structure on the Robustness

From the expressions derived in the previous section when A ∼ biSBM (θ, n), we are now able to study the average behavior of the robustness with respect to the mesoscale structure of the network encoded in θ.

Analytical Properties

First properties on R θ,n,S (m)

We first derive the following straightforward but useful properties of the robustness function and statistic: states that the uniform robustness automatically increases with the size n r of the network. However, it is important to note that these properties do not assess that the robustness is an increasing function of the connectance d.

Upper bound for the robustness under a uniform extinction sequence

We now aim at identifying mesoscale structures maximizing the average robustness under the joint distribution L θ,n,U . In order to remove the effect of the mean number of interactions a.k.a. the density d = k,q π k δ kq ρ q , we propose to compare structures encoded in θ leading to the same density value. We also fix the number of row species n r . Thus, for a given density d, we define the set Θ d = {θ = (π, ρ, δ) : k,q π k δ kq ρ q = d}. The following proposition provides an upper bound for the expectation of the robustness function and of the robustness statistic as a function of the density. It also identifies a condition on θ to achieve this upper bound. Eventually, it shows that the parametrization of an Erdős-Rényi distribution satisfies this condition and reaches the lowest variance of the robustness statistic among the parametrizations satisfying this condition.

≤ 1 - 1 n r (1 -d) -(1 -d) nr+1 d . ( 4
V A (R U (A)) = V E (R U (E)) .
In other words, among all parameters θ ∈ Θ max d,nr , the one of the Erdős-Rényi network minimizes the variance of robustness statistic R U (A) given in Proposition 4.3.

Proof.

1. Recall that R θ,(nr,nc),U (m) = 1 -Qc q=1 ρ q (1 -δ +q ) nr-m where δ +q = Qr k=1 π k δ kq for any q ∈ {1, . . . , Q r }. So, R θ,(nr,nc),U (n r ) = 0 and for R θ,(nr,nc),U (n r -1) = 1 -(1 -d) : the bound is true for m = n r and m = n r -1. Now, if 0 ≤ m ≤ n r -2, then x → x nr-m is a strictly convex function and the Jensen. inequality applies:

R θ,(nr,nc),U (m) = 1 - Qc q=1 ρ q (1 -δ +q ) nr-m ≤ 1 -   Qr q=1 ρ q (1 -δ +q )   nr-m (4.18) = 1 -   1 - Qr q=1 ρ q δ +q   nr-m = 1 -(1 -d) nr-m ,
2. Equality at line (4.18) holds if and only if the term inside the strictly convex function is constant, ie. for any q, q , δ +q = δ +q .

3. When we compute the variance given in Proposition 4.3(2) on any biSBM with θ ∈ Θ max d,nr , we notice that η q = η q = 1 -d and that only the term q,q ρ q ρ q η l-m q η l-m q η m+m -l qq varies. We can reformulate this quantity and use the Jensen inequality:

q,q ρ q ρ q η l-m q η l-m q η m+m -l qq = (1 -d) l-m (1 -d) l-m q,q ρ q ρ q η m+m -l qq (Jensen) ≥ (1 -d) 2l-m -m q,q ρ q ρ q k π k (1 -δ kq )(1 -δ kq ) m+m -l (Distributivity) = (1 -d) 2l-m -m k π k (1 - q ρ q δ kq )(1 - q ρ q δ kq ) m+m -l (Jensen) ≥ (1 -d) 2l-m -m k π k (1 - q ρ q δ kq ) 2 m+m -l = (1 -d) m +m (Initial term from ER)
Although the homogeneous distribution on the networks (Erdős-Rényi) leads to the maximum robustness in expectation for a given density, a particular realization of a network according to another distribution may be likely to have a larger robustness than a realization according to the Erdős-Rényi distribution. Indeed, the variance is larger when it corresponds to a distribution that represents a more complex structure. This behavior is illustrated in

Analysis for Typical Structures

We now illustrate numerically how the robustness statistic varies with respect to the network topology2 . For that purpose, we fix n r = n c = 100, Q c = Q r = 2, and π = (.25, .75) and make ρ vary. For j ∈ [1/8, 8], we consider the following connectivity matrices.

Modular: δ = j 1 1 j , each block of row species is strongly connected to a block of column species and lowly connected to the other.

Core-periphery: δ = j j j 1 .

• For j > 1, the structure is nested, the core is strongly connected to the whole network while the periphery is lowly connected with itself.

• For j < 1, the core is strongly connected with itself but the rest of the network is lowly connected.

Each connectivity matrix is then normalized such that the density of the network is equal to 0.0156, by applying the following transformation: δkq = 0.0156 δ kq k ,q π k δ k q ρ q ∀k, q ∈ {1, 2}. This value is chosen so the robustness statistic associated with an Erdős-Rényi distribution with density d = 0.0156 and n r = 100 rows is approximately equal to 0.5. We recall this value is an upper bound of the expectation of the robustness statistic under the joint distribution L θ,n,U where θ is such that the network has the same density and same number of rows.

The extinction sequence distributions are S ∈ {U, B ↑ , B ↓ } where B ↑ (resp. B ↓ ) corresponds to the block increasing (resp. decreasing) extinction sequences distribution defined in Equation (4.11). For every S, topology (modular or core-periphery) and value of j and ρ, we compute the expectations of the robustness statistics by using the expressions derived in Section 4.4. These expectations are displayed in the heat maps of Figure 4.3.

For modular networks, the plots are symmetric with respect to the central dot which corresponds to the case of an Erdős-Rényi distribution. The impact of the modular structure is slighter for S = U than for S ∈ {B ↑ , B ↓ }. For S = U, the strongest impact is observed when the modular structure is strong and the most connected blocks are slightly larger than the least connected ones (Fig. 4.3.♦). Keeping the same strong modular structure with the most connected blocks slightly smaller than the least connected ones (Fig. 4.3. ) leads to a negative impact on the robustness no matter S.

When the network is highly modular and the most connected block is small (j and ρ both small or both large, Fig. 4.3. ) the robustness is strongly impacted. This impact is negative for B ↓ and positive with B ↑ .

For a core-periphery structure, there is a clear asymmetry between j < 1 and j > 1.

The robustness statistic tends to be smaller when the core is mainly connected to itself, especially when the core is small (j < 1 and large ρ: In abscissa, j is a topology strength parameter. rho is the proportion of column species that belongs to the first column block. • represents a topology with no structure (Erdős-Rényi (ER)). Color gradient varies from blue (less robust than an ER), to white (as robust as an ER), to red (more robust than an ER). The symbols corresponds to the following mesoscale structures:

-large core, strongly connected only to itself, -small core, strongly connected to the whole network, -medium size core strongly connected only to itself, -highly modular with unbalanced blocks' sizes, ♦ -highly modular with slightly smaller highly connected blocks, -highly modular with slightly larger highly connected blocks.

Analysis of a collection of observed bipartite ecological networks

In this section, we analyse the robustness of a collection of 136 plant-pollinator, seed-dispersal or host-parasite networks, issued from the Web of Life dataset (www.web-of-life.es). The selected networks involve at least 10 row species and 10 column species.

When observing an interaction network, one can compute its empirical robustness as defined in Equation (4.3). However, understanding the behavior of the robustness statistic for any network with the same probabilistic distribution (i.e. with the same mesoscale structure) may also be attractive and informative. This can be done by positing a model on the network of interest, estimating the corresponding parameters (summarizing its structure) and deriving the moments of the robustness for these inferred parameters using Section 4.4 (either using a closed-form expression or a Monte Carlo integration, depending on the model). This expected version of the standard robustness may be considered as a new robustness indicator.

In what follows, we put in perspective the empirical robustness and its expected versions for the biSBM and DCbiSBM models (Subsection 4.6.1) and comment the systematic differences we observe. Then, we demonstrate the interest of the expected version when the network is partially observed (Subsection 4.6.2). Indeed, when inferring the bipartite SBM, the observational process that generates the observed network with possibly missing data could be taken into account [START_REF] Tabouy | Variational inference for stochastic block models from sampled data[END_REF]. This which allow us to compensate for observational biases in the empirical robustness.

Inferring the biSBM and DCbiSBM The parameters of these two models can be inferred by a variational version of the Expectation-Maximization (EM) algorithm.

The number of blocks is chosen according to an Integrated Classification Likelihood (ICL) criterion [START_REF] Daudin | A mixture model for random graphs[END_REF]. This variational EM algorithm is theoretically grounded [START_REF] Bickel | Asymptotic normality of maximum likelihood and its variational approximation for stochastic blockmodels[END_REF] and has proven its pratical efficiency [START_REF] Daudin | A mixture model for random graphs[END_REF][START_REF] Mariadassou | Uncovering latent structure in valued graphs: a variational approach[END_REF]. In practice for the inference of these models, we use the blockmodels R package [START_REF] Leger | blockmodels: Latent and Stochastic Block Model Estimation by a 'V-EM[END_REF] and to handle missing observations the GREMLINS R package (Bar-Hen et al., 2020), both available on CRAN .

Computation of the Robustness for the Web of Life Dataset

For each network A, on the one hand, we compute the empirical robustness R U (A) using 300 Monte Carlo realisations. On the other hand, for each model (biSBM and DCbiSBM) we denote θ (resp. θ, γ) the estimated parameters and compute the expectations of the robustness under each model. For the biSBM, we also supply their variance and define the ratio

Z R (A) =| R U (A) -R θ,n,U | / V θ,n ( E U [ R(A, S)|A ] )
which is the number of standard deviations separating the two computed robustness statistics. This quantity helps assess the goodness of fit of the biSBM to the network A with respect to the robustness statistic. biSBM versus DCbiSBM In Figure 4.4, we plot the points ( R U (A), R θ,n,U ) for the two models (circles are for biSBM and purple triangles for DCbiSBM). For the biSBM, the color of the point depends on (1 -d) nr which is the estimated probability to observe a column with no interaction. The observed robustness indicators range from 0.5 to 1. The points roughly follow the identity line for the biSBM (circles) whereas the expected version seems systematically smaller than the empirical robustness for the DCbiSBM (purple triangles). We comment further on these points hereafter.

• Under a biSBM, the smaller (1-d) nr , the smaller | R U (A)-R θ,n,U | and Z R (A) (the number of standard deviations). When (1 -d) nr is large (red dots), the expected version of the robustness under a biSBM underestimates the standard robustness (red dots at the bottom left of the plot). This phenomenon may be explained as follows. By construction, ecological networks only involve species that have been seen at least one time in interaction (species with no interaction were removed). As a consequence, since the biSBM does not take into account this phenomenon, the space of networks we integrate over when computing the robustness statistic under a biSBM is too large. This remark is especially true for small networks and highlights the limitation of the biSBM model for small ecological networks.

• On 127 networks (over the 136), the DCbiSBM selects 1 block, encoding solely, as the EDD model, the degree distribution and the size of the networks in their parameters. On these networks, the expectation of the robustness statistic under a DCbiSBM is smaller than the empirical robustness most of the time (purple triangles). We can conclude that the DCbiSBM seems to be unable to capture the additional structure beyond their degree distribution that makes them more robust to uniform random extinction than expected.

This first study highlights the limitation of the DCbiSBM model to mimic ecological networks (hence, hereafter, we focus our analysis solely on the biSBM). On the contrary, for not too small networks, the expected version of the robustness with biSBM supplies coherent robustness values with the empirical indicator R U (A). This new version of the robustness has the advantage to arise in a closed-form and a quantification of its variance is available. This comparison has been made for S = U, we now consider more elaborate extinction sequence distributions.

About S. We compute the robustness statistics for decreasing and increasing primary extinction sequences on the degrees with the two methods described in Section 4.2: the one which strictly depends on the order of the degrees ( R As a conclusion, the degree decreasing sequences standardly used in the ecological field can be easily reproduced with our block decreasing connectivity sequences, leading to quite comparable values. Once again, our expected version of the robustness can be calculated in a closed-form while the empirical robustness relies on a computationally expensive Monte Carlo integration. The degree decreasing extinction sequences are very sensible to the most highly connected species leading to no agreement between the two versions of the robustness.

Correction for Partially Observed Networks

Although the ecological networks are often considered to describe all the possible interaction between species, the sampling may be incomplete [START_REF] Blüthgen | What do interaction network metrics tell us about specialization and biological traits[END_REF] which may bias the computed network statistics (Rivera-Hutinel et al., 2012) such as the robustness. By relying on a probabilistic model such as the biSBM which can be adjusted to account for the observation process, the sampling effect on the robustness can be corrected. We assume that we could have obtained the true interaction network if the sampling effort has been large enough. Instead of this true network, we have only a partially observed interaction network that corresponds to a subset of the true network. We assume that one of the two following frameworks may have generated missing data:

Partially observed species 25% of both the row species and the column species are removed uniformly at random, resulting in the following networks subset: A obs = {A ij : i and j are observed}. In this framework, we need to assume that some other data or some expert knowledge gives us the true number of species and the density of the true network. By relying on this expert knowledge, we are able to adjust the parameters of the biSBM.

Partially observed interactions

The observation process consists of the observation of interaction on two different transects T 1 and T 2 . Since not all the species are present on both transects, the interactions between the species which were not observed on the same transect are labelled as missing and encoded by NAs. This results in the following modified incidence matrix:

A obs =      j ∈ {T 1 ∩ T 2 } j ∈ {T 1 \ T 2 } j ∈ {T 2 \ T 1 } i ∈ {T 1 ∩ T 2 } A ij A ij A ij i ∈ {T 1 \ T 2 } A ij A ij NA i ∈ {T 2 \ T 1 } A ij NA A ij     
.

More precisely, we consider that on average 50% of the species were observed on both transects while 25% were just observed on one of the two transects and select those species uniformly at random, resulting in 12.5% of missing interactions on average. Note that in this case, we do not need any expert or additional knowledge to have an unbiased estimation of the biSBM parameters.

It is sufficient that the missing values are taken into account in the biSBM inference.

We performed a simulation study where we considered 98 networks from the web of life dataset as the true interaction networks. We kept the 98 networks where (1-d) nr < .1 and the error in terms of standard deviation is smaller than 1. For each of these 98 networks, we simulated the two observation processes described above 30 times, then we computed the standard robustness statistic and its expectation under a biSBM. For for each of the 98 fully observed networks A and where the Ãb 's are realizations of a partial observation of A. In order to get the robustness under a biSBM, the biSBM was first inferred by taking into account missing data and the robustness statistics were then computed under the inferred biSBM. We computed the corresponding RMSE for the distributions on extinction sequences S ∈ {U, B ↑ , B ↓ } as:

1 30 30 b=1 (R θ,n,S -R θb ,n,S ) 2
where θ is estimated from the fully observed network and the θb 's are estimated from partial observations of the network. Note that the numbers of species in row and in column are the same for the fully and the partially observed networks even in the case of missing species since we assumed that we had some additional knowledge which provided us with this information.

The errors in the prediction of the robustness statistics computed from partially observed networks are much smaller when computing the robustness under a biSBM than when using MC computations. Indeed, the missing data can be accounted for in the biSBM inference and the underlying structure of the network can still be recovered from partial information whereas the Monte Carlo simulations are more sensitive to perturbations in the network. The extinction sequences which depend strictly on the degrees are the most impacted by a partial observation of the network. This impact is rather strong although only 12.5% of the information is missing. Note that adding some randomness in the primary extinction sequences by using a distribution which depends linearly on the degrees instead of a strict order has a stabilizing effect. In the framework with partially observed species we assumed that we had additional knowledge giving us access to the true number of species and network density. In practice, this is not always the case. When details about the sampling of networks are available, a few methods exist in the literature to estimate the number of species (Jiménez-Valverde et al., 2006; Gotelli and Colwell, 2011) and similar methods could be used to estimate the density. One could then plug these estimates in the formula of robustness. If neither the sampling scheme nor the expert knowledge is available, the true number of species remains unknown. Note that in most available ecological interaction networks, the number of species is underestimated as species which have not been seen in interaction with other species are not included in the network. Finally, having access to the number of species, but not to the true number of interactions, leads to an underestimated robustness.

Discussion

We proposed an expected version of the empirical robustness for bipartite ecological interaction networks by considering a joint model on the network and on the primary extinction sequences. In particular, we obtained a closed and tractable form of the robustness when considering a biSBM as the network model for uniform and by blocks primary extinction sequences. We validated our method by showing that the obtained values were consistent with the empirical robustness classically used in the ecological network community. Having analytical forms allows us to better understand the impact on the robustness of the topology of the network in terms of number of species, density, and mesoscale connectivity patterns. Furthermore, we used the difference between the empirical and expected versions to show that the biSBM is better suited than the DCbiSBM for bipartite ecological networks. This could come from the fact that the DCbiSBM tends to favor community structure above core-periphery structure (Newman, 2018, 14.7.3). The core-periphery structure is indeed very common in bipartite ecological networks which has a strong impact on the robustness.

On real networks, this method can serve as an alternative to the traditional empirical approach, especially when networks are partially observed (because of the inference stability of the biSBM) or when the sampling effort is incomplete (because the model parameters can be easily corrected). This step could be improved with more precise information by considering specific sampling schemes in the model [START_REF] Tabouy | Variational inference for stochastic block models from sampled data[END_REF] or by obtaining more details on the sampling in order to better estimate the parameters block by block. Moreover, from the observation of a network, the impact of some hypotheses on the structure might be tested by tuning some parameters of the models and computing the corresponding expected robustness. It may also help study the impact of the structure beyond the effect of the number of species or density when comparing the robustness of several networks: indeed, once the biSBM parameters are estimated, the robustness statistics can be computed by setting the same numbers of species and the same density for all the networks.

Although we developed our method for bipartite networks, this approach can be extended to other types of networks in particular multipartite networks [START_REF] Pocock | The robustness and restoration of a network of ecological networks[END_REF]) and food webs. Multilayer networks (multiplex or multipartite networks) are gaining a lot of attention with scholars studying ecological networks [START_REF] Hutchinson | Seeing the forest for the trees: Putting multilayer networks to work for community ecology[END_REF]. Extending this framework to multipartite networks by including cascading effect between layers is an interesting perspective once data will be more readily available. The study of robustness for food webs is quite active but requires some ecological insight to properly model the food web as some species are basal species and thus do not prey on other species (in-degree is 0). So food webs which are usually blockmodeled by a directed stochastic block model, might be better handled in our case using a multipartite block model with basal species as a functional group of its own. In this case, it might be important to incorporate rewiring or cascading mechanisms to the modeling of the extinctions. A direction to look at in order to deal with the extinction of basal species and the incorporation of cascading mechanisms is the approach of Bayesian networks to model species extinction in food webs [START_REF] Eklöf | Secondary extinctions in food webs: a bayesian network approach[END_REF][START_REF] Häussler | A bayesian network approach to trophic metacommunities shows that habitat loss accelerates top species extinctions[END_REF].

Lastly, we believe that other ecological indicators could be estimated through a parametric model based approach. Especially, the EDD model and the DCbiSBM seem particularly well suited to study nestedness (see [START_REF] Mariani | Nestedness in complex networks: observation, emergence, and implications[END_REF], for a review) which is a widely used statistic for ecological networks. Proof. Let us assume without loss of generality that the primary extinction sequences go from block 1 to block Q r . Under this assumption, P(S = s|Z) =

1 Z s(1) ≤•••≤Z s(nr )
#{s:Z s(1) ≤•••≤Z s(nr ) } . Thus, an extinction sequence which does not maintain the block ordering has a null probability. Then, conditioning first by the blocks memberships then the primary extinction sequences: (1 -α k s(i) q )   .

We have for all sequences s, s in the support of S | Z, that for all i, Z s(i) = Z s (i) . Hence, using the exchangeability properties of the biSBM for species belonging to the same block: nr i=m+1 1 -α k s(i) q = nr i=m+1 1 -α k s (i) q . Furthermore, This leads to: ρ q ρ q (η q η q ) l-m η 2m-l qq .

The variance of the robustness statistic due to the network variability under a

given biSBM is: ρ q ρ q η l-m q η l-m q η m+m -l qq .

V A [R U (A)] = 1 n 2 r n 2
Proof. The calculus of the following proof relies on the following lemma: Proof. There are n! permutations of size n. For the first permutation of size n, we look at the first m . In order to create the second permutation we must among the first m terms take:

• l -m terms that are not common with the first permutation (among n -m)

• m + m -l terms that are common with the first permutation (among m). The bound on l is straightforward.

We first prove the result for the robustness statistic. The variance of the robustness function is a straightforward derivation from it. To compute B1, we separate the set of the union of the extinction sequences into 3 disjoint sets in order to distribute the mixture parameter π:

B1 = 1 n r !n r ! s,s ∈Sn r E π,ρ    E α 1 { nr i=m+1 A s(i)j =0} 1 { nr i=m +1 A s (i)j =0} |Z, W    = 1 n r !n r ! s,s ∈Sn r E π,ρ   nr i=m+1 (1 -α Z s(i) W j ) nr i=m +1
(1 -α Z s (i) W j )   = 1 n r !n r ! s,s ∈Sn r q,q ρ q ρ q k 1:nr π k 1:nr nr i=m+1

(1 -α k s(i) q ) nr i=m +1

(1 -α k s (i) q ) = 1 n r !n r ! s,s ∈Sn r q,q ρ q ρ q k 1:nr For B2, the column indices are the same, hence some entries of A are taken twice: B2 = 1 n r !n r ! s,s ∈Sn r q ρ q k 1:n π k 1:n E α 1 { i∈s(m+1:nr )

A ij =0}
•1 { i ∈s (m +1:nr )

A i j =0} |Z 1:nr = k 1:nr , W j = q = 1 n r !n r ! s,s ∈Sn r q ρ q k 1:n

π k 1:n •E α 1 {

4.B. Comparing the robustness of bipartite ecological networks with different interaction types

In this appendix we aim at understanding the link between the robustness and different basic statistics such as the number of species and the network density on the networks issued from the Web of Life database presented in Section 4.6. Some of these links has been studied theoretically on Section 4.5 of this chapter. We will illustrate how the package robber may help us to compare the robustness of a collection of networks.

4.B.1. Robustness and Analysis of the block model of the Web of Life dataset

The collection we consider is comprised of 3 types of interaction bipartite networks encoded as :

A_HP for hosts-parasites with parasitism (antagonistic) interactions,

Richness and connectance of the Web of Life dataset

In the next figure, we show boxplots of the empirical robustness for the three interaction types and three distributions of the primary extinction sequences (D ↓ ord , D ↑ ord , U). We notice that pollination networks have a much lower robustness to plant extinctions than seed-dispersal networks. Also, the distribution of the robustness of parasitism networks does not seem to vary much depending on the extinction sequence. We will explore this further by fitting linear models on these statistics.

Linear Model for Empirical Robustness

From now on, we just keep 71 networks. Some networks come from time series, where we just keep the most complete network for each time series. Others were outliers on the linear model described below, breaking the Gaussian linear model assumptions. We note by index10ERno this new subset of networks. We make multiple linear regression by fitting a linear model with 5 covariates, which are the species richnesses: n r and n c the connectance of the network d and the probability to have an empty row (1 -d) nc or column (1 -d) nr under an Erdős-Rényi model to explain one robustness statistic at a time. The response variables are the empirical robustness statistic with S ∈ {D ↓ ord , D ↑ ord , U} as the distribution of the primary extinction sequences. In order to assess the effect of the type of interactions beyond these basic statistics, we fit an ancova model were we add the type of interactions as a qualitative covariate. fit.lm <-lm(robustness ~connectance + nr + nc + empty_row + empty_col, subset = index10ERno,data = tb_emp_stat) fit.ancova <-lm(robustness ~type*(connectance + nr + nc + empty_row + empty_col), subset = index10ERno,data = tb_emp_stat)

The link between the basic statistic and the empirical robustness is significant for all 3 primary extinction sequence distributions (not shown here). In Table 4.1 we show for each type of robustness statistic, an analysis of variance table of the multiple linear model versus the ancova model, testing for the added effect of the type of interaction. We see that the adjusted R 2 is very high (≈ .9) for the multiple linear regression model for S = U. This show further evidence that the empirical robustness usually computed is well explained by the connectance and species richness of the network. This is also true for S = D ↓ ord , but not so much for D ↑ ord . We think that the last results is due to the importance of the most connected species in the robustness, an information which is not directly included in the covariates we used. When we test the two nested models, we see that adding the effect of the interaction type is significant for S ∈ {D ↑ ord , U}, but not for S = D ↓ ord .

4.B.3. Normalized robustness

In order to try removing the effect of species richness and connectance from the robustness and to understand which networks have a more robust structure we can reparametrized the parameters of the biSBM so that each network has the same new richness ñ and connectance d, by doing: ñr = ñc = 100 δkq = .0156 d δkq , ∀(k, q) ∈ {1, . . . , Qr } × {1, . . . , Qc }, where d = .0156 has been chosen so that the robustness statistic under an Erdős-Rényi model is about .5. We then compute the normalized biSBM robustness statistic with S ∈ {B ↓ , B ↑ , U} as the distribution of the primary extinction sequences.

tb_robustness_norm <tibble("uniform.norm" = unlist(compare_robustness(lbm_param)), "decreasing.norm" = unlist(compare_robustness(lbm_param, ext_seq = "decreasing")), "increasing.norm" = unlist(compare_robustness(lbm_param, ext_seq = "increasing")))

We show above that the empirical robustness is highly dependant on the richness and connectance. Also, there seems to have an additional effect of the type of interaction for decreasing and uniform extinction sequences. Using the biSBM robustness with normalized parameters should remove a part of this dependence. On the next figure, we plot the normalized biSBM robustness for all 3 types of extinction sequences. The shape of the distribution seems to differ depending on the type of interaction but the center of the distribution looks close. lbm_param.T <-lapply(lbm_param, function(par) list(con = t(par$con), pi = par$rho, rho = par$pi)) tb_robustness_norm.T <tibble("uniform.norm.T" = unlist(compare_robustness(lbm_param.T)), "decreasing.norm.T" = unlist(compare_robustness(lbm_param.T, ext_seq = "decreasing")), "increasing.norm.T" = unlist(compare_robustness(lbm_param.T, ext_seq = "increasing")))

In the next figure, we notice on the left a clear asymmetry for pollination networks in the empirical robustness depending on wether the primary extinction sequences is on the plants or on the pollinators. This is an effect of the asymmetry in the species richness, ie. in the number of plants and pollinators in these networks. In most of them, there are more pollinators than plants (n c >> n r ) and the networks are more robust to pollinator extinction than to plant extinction. When looking at the normalized robustness, we notice that networks are evenly distributed around the first bissectrice, except for decreasing by block primary extinction sequences where there seems to be a slight bias for pollination networks. Les covariables environnementales (resp. phénotypiques) agissent de manière homogène sur l'ensemble du réseau multi-omique :

β k,k qr = β 0 (resp. γ k,k qr = γ 0 ), ∀(k, k , q, r) ∈ K × Q k × Q k ,
ou bien sur une famille de relation omique particulière :

β k,k qr = β k,k 0 (resp. γ k,k qr = γ k,k 0 ), ∀(q, r) ∈ ×Q k × Q k .
Analyser les valeurs de β (resp. γ) peut permettre alors de comprendre quels types d'interactions omiques sont influencées par les covariables environnementales (resp. phénotypiques).

Robustesse de collections de réseaux

Je souhaiterais également étendre les travaux sur les collections de réseaux à des collections de réseaux bipartites et multipartites. L'extension aux réseaux multipartites est un moyen naturel de relier ces travaux à ceux effectués sur la robustesse. Nous avons vu au chapitre 3 que la modélisation par collection de réseaux a un effet stabilisateur sur le clustering obtenu et que considérer des informations provenant d'autres réseaux pouvait améliorer la prédiction d'arêtes, et cela, même sur des réseaux faiblement bruités. L'échantillonnage des réseaux écologiques étant connu pour être incomplet [START_REF] Blüthgen | What do interaction network metrics tell us about specialization and biological traits[END_REF], il serait intéressant d'analyser l'effet de stabilisation du modèle apporté par la modélisation jointe sur la robustesse par SBM bipartite. Étudier des collections de réseaux bipartites permettrait également en intégrant des covariables pour le types d'interaction, de déterminer l'effet du type d'interaction écologique sur la structure du réseau. Cela nous aiderait enfin à quantifier l'effet du type de l'interaction sur la robustesse. Robustesse de réseaux tripartites Les travaux sur la robustesse peuvent également être étendus aux réseaux multipartites. Par exemple, Domínguez-García and Kéfi (2021) ont agrégé une collection de réseaux tripartites, mutualiste-mutualiste, mutualiste-antagoniste et antagoniste-antagoniste, et étudient leurs robustesses. Dans ces réseaux, lorsque les extinctions ont lieu sur un groupe fonctionnel en particulier, il est nécessaire d'incorporer un système de cascade dans les extinctions pour étudier les conséquences de ces extinctions sur des espèces qui ne sont pas directement en interaction avec ce groupe fonctionnel. Je donne ci-dessous quelques détails sur l'incorporation des cascades d'extinctions dans le cadre d'un SBM tripartite. Supposons que les extinctions primaires aient lieu sur la première couche, impliquent des extinctions secondaires sur la seconde couche et que les espèces de la troisième couche ne soient en interaction avec celles de la première couche. Alors, l'impact des extinctions primaires sur la troisième couche ne se fait que via les extinctions secondaires. Alors, on intègre un système de cascade sur les espèces de la troisième couche de la manière suivante. Soit

S

(2)

j (m) := 1{ n 1 i=m+1
X 1,2 S(i)j > 0}, l'indicatrice de l'évènement de non extinction secondaire de l'espèce j après m extinctions primaires. Alors, P (X,S) (S

j (m) = 1) est directement calculable à partir des résultats sur les réseaux bipartites du chapitre 4. Cela nous donne pour chaque espèce de la seconde couche, une probabilité d'extinction secondaire à partir de laquelle nous pouvons conditionner les extinctions de la dernière couche. Ainsi, en notant S The stochastic block model has proven its relevance to model the heterogeneity of the behavior of nodes in a single network. Extensions to collections of networks and to multilevel networks are proposed. They allow to obtain a clustering of the nodes of the networks according to their role in the ecosystem or social system, and to summarize the structure of the system at the mesoscopic scale through a small number of parameters. The inference of these models is complex and variational methods are adapted for this purpose.

Model selection methods are also used to determine the dependence between levels for multilevel networks and the similarity between structures for collections of networks. A last part of this thesis proposes a new method to study the robustness of ecological interaction networks. Each network is modeled by a probabilistic model whose parameters represent the network structure. This allows to make the link between the structure of the ecosystem and its robustness, but also to compare the robustness of a collection of networks and to correct the robustness of a network whose sampling would be incomplete. The developed methods are implemented in R packages and applied on data from social sciences and ecology.

1. 1 2 . 5

 125 Nombre de documents incluant les mots "multilayer networks" par période de 5 ans sur Google Scholar. . . . . . . . . . . . . . . . . . 1.2 Représentation d'un réseau jouet de pollinisation et de sa matrice d'incidence. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1.3 Haut-gauche -Structure communautaire assortative : α a = ( .8 .1 .1• .6 .05• • .6 ) and π a = (.3, .3, .4), Haut-droite -Structure coeur-périphérie avec un semi-coeur : α cp = ( .8 .5 .2• .3 .1• • .05 ) and π cp = (.2, .3, .5), Bas-gauche -Structure communautaire disassortative : α d = ( .1 .4 .5• .05 .4• • .05 ) and π d = (.2, .4, .4) A : Matrice d'un réseau de 50 noeuds généré aléatoirement d'après la structure donnée, B : La même matrice réordonnée par appartenance aux blocs, C : Vue de type graphon des paramètres du modèle, D : Réseau généré, la couleur des noeuds correspond aux blocs d'appartenances, E : Vue méso-échelle des paramètres du modèle, la taille des noeuds représente la cardinalité du bloc (paramètre π) et la largeur et l'intensité des arêtes désignent la probabilité de connexion (paramètre α). . . . . . . . . . . . . . . . . . 1.4 Gauche : DAG d'un SBM à 3 noeuds. Droite : graphe moral associé au DAG. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1.5 Représentation d'un réseau multiniveau avec le niveau interorganisationnel en haut et le niveau inter-individuel en bas. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.1 Matrix representation of a multilevel network . . . . . . . . . . . . 2.2 DAG of the stochastic block model for multilevel network (MLVSBM) 2.3 MLVSBM with inter-organizational level on the top and interindividual level on the bottom. The various shades of blue depict the clustering of the individuals and the various shades of red depict the clustering of the organizations. The parameters α over the plain links between nodes are the probabilities of connections given the nodes colors (clustering/blocks). The outer circles around the nodes of the individuals represent the blocks of the organizations they are affiliated to. The dashed links stand for the affiliations. . . . . . . . 2.4 Clustering and model selection for 3 different topologies on the interindividual level, varying and density d. Each situation is simulated 50 times. A: ARI for the inter-individual level, comparing the model used for inference. B: Stacked frequency barplot of the selected number of blocks for the inter-individual level in the MLVSBM (in blue). C: Stacked frequency barplot of the selected number of blocks for the inter-individual level chosen in the SBM (in red). . . . . . . Clustering and model selection for 3 different topologies on the interindividual level, as function of δ and density d. Each situation is simulated 50 times. The yellow vertical lines represent a δ = 1/3 (i.e. a γ with uniform coefficients, resulting into independence between the two levels). A: ARI for the inter-individual level, comparing the model used for inference. B: Stacked frequency barplot of the selected number of blocks for the inter-individual level in the MLVSBM. C: Stacked frequency barplot of the selected model with respect to inter-level dependence. . . . . . . . . . . . . . . . . . . . . . . . . . 2.6 AUC of the prediction for A: missing dyads, B: missing links, in function of the missing proportion for the inter-individual level. Colors represent different network at the inter-organizational level. None (beige) is equivalent to a single layer SBM on the individuals. The confidence interval is given by mean ± stderror. . . . . . . . . . . . 2.7 Multilevel network of the Promoshow East trade fair 2011. Above: the deal network for the organizations and below: the advice network for the individuals. A: Mesoscopic view of the multilevel network. Nodes stand for the blocks, donut charts show the relation between Z O and Z I . Black edges are the probabilities of connection α I and α O , blue edges stand for P(X I ii = 1|Z O A i , Z O A i ), i.e. the probability of interaction between organizations through their individuals. For sake of clarity only edges with probabilities above the density are shown. B: View of the network. The size of a node is proportional to its indegree. Colors represent the clustering obtained with the MLVSBM. C: Matrix representation of the multilevel network. At the bottomleft, the adjacency matrix of the advice network between individuals, at the top-right, the deal network between organizations, at the topleft, the affiliation matrix of the individuals to the organizations. Entries are reordered by block from left to right and bottom to top. Blocks are separated by thin lines and levels by thick lines. The entries of the bottom-right matrix are the parameters α I , γ and α O multiplied by 100. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.8 DAG of the generalized Stochastic Block Model for Multilevel Network (gMLVSBM) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.1 Matricial view of 3 stream food webs. The species are reordered by blocks and blocks are ordered by expected out-degrees to emulate the trophic levels (bottom to top and right to left). The blocks have been obtained by fitting a SBM on each network separately. . . . . . . . 3.2 Partition of networks. ARI of the recovered partition of networks. Orange is for the iid-colSBM , green for the δ-colSBM , purple for the δπ-colSBM and yellow for the π-colSBM . . . . . . . . . . . . . 3.3 Finding finer block structures. Cumulative barplot of Q by the SBM s (blue) and the adequate colSBM (red) under the different simulation scenario. The number of blocks to be recovered is 3 and the darkest shade corresponds to Q = 3. . . . . . . . . . . . . . . .

4. 1

 1 Robustness function computed from a set of biSBM parameters (plain black) and by Monte Carlo for 10 networks generated from the same biSBM distribution (dotted) for block decreasing, uniform and block increasing primary extinction sequences. The grey ribbon on the uniform facet is twice the standard error given in Proposition 4.3. . 4.2 Density curve of the distribution of the expectation of the robustness statistic under biSBMs of the same size and density with three different sets of parameters. Each network is simulated from a given set of parameters, then the robustness is computed by the Monte-Carlo approximation given in (4.4). 500 simulations each. . . . . . . . . . 4.3 Robustness for different biSBM topologies. Primary extinction sequences are displayed in rows and topologies in columns.

  . . . . . . . . . . . . . . . . . . . . . . . 4.4 Expected robustness statistic (R θ,n,U ) under a biSBM (circles) and DCbiSBM (purple triangles) as a function of the standard robustness ( R U (A)) for uniform extinction sequences. The grey to red gradient stands for (1 -d) nr , the probability to have an empty column under an Erdős-Rényi distribution. The size of the point is related to Z R (A). xvi List of Figures 4.5 R θ,n,S as a function of the classical robustness R D (A) for various S.

1. 1 . Motivation 3 Figure 1 . 1 -

 1311 Figure 1.1 -Nombre de documents incluant les mots "multilayer networks" par période de 5 ans sur Google Scholar.

Figure 1 . 2 -

 12 Figure 1.2 -Représentation d'un réseau jouet de pollinisation et de sa matrice d'incidence.

Figure 1 . 3 -

 13 Figure 1.3 -Haut-gauche -Structure communautaire as-sortative : α a = .8 .1 .1 • .6 .05 • • .6 and π a = (.3, .3, .4), Haut-droite -Structure coeur-périphérie avec un semi-coeur : α cp = .8 .5 .2 • .3 .1 • • .05 and π cp = (.2, .3, .5), Bas-gauche -Structure communautaire disassortative : α d = .1 .4 .5 • .05 .4 • • .05 and π d = (.2, .4, .4) A : Matrice d'un réseau de 50 noeuds généré aléatoirement d'après la structure donnée, B : La même matrice réordonnée par ap-partenance aux blocs, C : Vue de type graphon des paramètres du modèle, D : Réseau généré, la couleur des noeuds correspond aux blocs d'appartenances, E : Vue méso-échelle des paramètres du modèle, la taille des noeuds représente la cardinalité du bloc (paramètre π) et la largeur et l'intensité des arêtes désignent la probabilité de connexion (paramètre α).

  interactions entre blocs, U et V sont des vecteurs de dimension Q modélisant un effet envoyeur et receveur, tandis que W * est un scalaire représentant un biais pour modéliser la parcimonie. Modèles dynamiques Certains travaux s'intéressent à des réseaux dynamiques, dont les interactions entre noeuds peuvent se répéter au cours du temps. La loi des arêtes est alors un processus stochastique. Le SBM peut être utilisé pour modéliser ce genre de données. Dans ce cas, les interactions sont indépendantes et suivent un processus de comptage (Poisson inhomogène) dont le paramètre d'intensité dépend des blocs des noeuds concernés (DuBois et al., 2013; Matias et al., 2018). Formulation microcanonique De même qu'il existe une formulation G(n, m) en plus d'une formulation G(n, p) pour le modèle Erdős-Rényi ou le modèle EDD avec le modèle de configuration, Peixoto (2016) propose une formulation microcanonique du SBM Poisson et sa version avec degré corrigé. Pour cette dernière, il fixe des contraintes dures sur le degré de chaque noeud en plus du nombre d'arêtes entre chaque bloc et du nombre de noeud dans chaque bloc.

  Certains travaux (ex : Stanley et al., 2016; Tarres-Deulofeu et al., 2019) s'intéressent à trouver un clustering des couches en plus de celui des noeuds. Stanley et al. (2016) considèrent une partition des M couches en S strates. Dans chaque strate s ∈ {1, . . . , S}, les noeuds sont répartis dans |Q s | blocs indépendamment avec probabilités π s . Connaissant les strates et les appartenances aux blocs il y a indépendance des lois de chaque arête :

  Sur les modèles SBM pour réseaux dynamiques, je signale les récentes revues de Kim et al. (2018) et Lee and Wilkinson (2019). Des modèles dynamiques ont déjà été décrits dans les extensions du SBM section 1.2.3 (DuBois et al., 2013; Matias et al., 2018). Ici, nous sommes concernés par l'observation de réseaux en plusieurs points du temps ou de l'espace. L'évolution des blocs est modélisée par une chaine de Markov cachée. Des travaux considèrent également différents régimes à travers le temps, en classifiant des intervalles de temps en plus des noeuds (Corneli et al., 2016). Yang et al. (2011) proposent un SBM dont les blocs varieraient dans le temps, en dépendant du bloc au temps précédent, i.e. pour un réseau à T temps : P(Z t+1 i Introduction (fr)

  Dans le cadre du SBM, l'objectif de la plupart des algorithmes d'inférence est de retrouver les blocs d'appartenance et d'estimer les paramètres du modèle. Pour un grand nombre de SBMs, une fois les blocs retrouvés, l'estimation des paramètres est triviale. Il existe une grande diversité dans les méthodes d'inférence. Des méthodes Monte Carlo par Chaîne de Markov (MCMC) ont été développées avec un échantillonneur de Gibbs (Snijders and Nowicki, 1997; Nowicki and Snijders, 2001). Ces méthodes sont très coûteuses et ne permettent d'inférer que des petits réseaux. Ainsi, des travaux ont tenté d'en améliorer les performances, en proposant pour un nombre quelconque de blocs d'autres échantillonneurs (McDaid et al., 2013) ou en développant des heuristiques ayant des performances équivalentes mais computationnellement bien moins coûteuses qu'un MCMC exact (Peixoto, 2014a; Kuhn et al., 2020). Une autre famille de méthode très utilisée est celle des approches variationnelles (Jordan et al., 1999; Blei et al., 2017) que je développe plus en détail ci-dessous. Je mentionne également des méthodes d'inférence basées sur la méthode des moments (Bickel et al., 2011) ou sur la distribution des degrés empiriques (Channarond et al., 2012). De nombreuses revues de la littérature traitent des méthodes d'inférence pour le SBM (Lee and Wilkinson, 2019; Matias and Robin, 2014). Certaines se focalisent sur les résultats théoriques des différentes approches disponibles et leurs limites fondamentales (Abbe, 2016; Zhao, 2018), tandis que d'autres se concentrent sur la comparaison empirique de l'efficacité des différents algorithmes (Funke and Becker, 2019; Ghasemian et al., 2020a).

Figure 1 . 4 -

 14 Figure 1.4 -Gauche : DAG d'un SBM à 3 noeuds. Droite : graphe moral associé au DAG.

  Deux approches existent pour la valeur de Ẑ, Biernacki et al. (2000) proposent de remplacer Ẑ par le maximum a posteriori (MAP) de Z|X, i.e. Ẑi = arg max q∈Q P(Z i = q|X), alors que McLachlan and Peel (2000) suggèrent d'utiliser l'estimateur de l'espérance conditionnelle Ẑi = E[Z i |X]. Dans le cadre de l'inférence variationnelle, Ẑ est choisie comme étant le MAP des paramètres variationnels, i.e. Ẑi = arg max q∈Q τ iq ou bien par les paramètres variationnels eux-mêmes. Pour un SBM sur un réseau simple et non dirigé, la pénalité est donnée par :

  du VEM à l'estimation bayé-sienne par MCMC. Inférence en ligne et hors ligne. spec-tral et de l'EMV (M → ∞) sur les chan-gements de connections entre couches

NMI 1 2

 1 Soit (C, D) ∈ Q n × Q n deux vecteurs aléatoires de clustering des noeuds, alors le NMI vaut : NMI(C, D) = H(C) + H(D) -H(C, D) (H(C) + H(D)) Introduction (fr)

  On peut alors réécrire l'ARI à partir des 4 termes d'adéquation de couple de dyades définis ci-dessus : ARI(C, D) = a 11 -(a 11 +a 10 )(a 11 +a 01 ) a 11 +a 10 +a 01 +a 00 1 2 (a 11 + a 10 + a 01 + a 00 ) -(a 11 +a 10 )(a 11 +a 01 ) a 11 +a 10 +a 01 +a 00 . (1.8) L'ARI vaut 1 si les deux partitions sont les mêmes et est positif si les partitions comparées sont plus semblables qu'en espérance, i.e. RI(C, D) > E[RI(C, D)].

  .

5

 5

  .

  For instance, Zijlstra et al. (2006) adapt the p2-model to handle multiple observations of a network, Sweet et al. (2014) extend the Mixed Membership Stochastic Block Model (Airoldi et al., 2008) to the hierarchical network model framework (Sweet et al., 2013) for the same type of data. Snijders (2017) discusses the use of the stochastic actor-oriented model (Snijders, 2001) for temporal and multivariate networks. When dealing with the multilevel networks we defined before, Wang et al. (2013) adopt an exponential random graph model (ERGM) strategy that is used in applications across many fields such as environmental science (Hileman and Lubell, 2018) or sociology (Lazega and Snijders, 2015, chapter 10-11, 13-14)

Figure 2 . 1 -

 21 Figure 2.1 -Matrix representation of a multilevel network

Equations ( 2

 2 .3), (2.4) and (2.5) define a joint modeling of X I and X O . In what follows, we set θ = {π O , γ , α O , α I } the vector of the unknown parameters, X = {X I , X O } are the observed variables and Z = {Z I , Z O } the latent variables. The DAG of the MLVSBM is plotted in Figure 2.2. An illustration of the MLVSBM for a small multilevel network is represented in Figure 2.3.

Figure 2 . 2 -

 22 Figure 2.2 -DAG of the stochastic block model for multilevel network (MLVSBM)

Figure 2 . 3 -

 23 Figure 2.3 -MLVSBM with inter-organizational level on the top and inter-individual level on the bottom. The various shades of blue depict the clustering of the individuals and the various shades of red depict the clustering of the organizations. The parameters α over the plain links between nodes are the probabilities of connections given the nodes colors (clustering/blocks). The outer circles around the nodes of the individuals represent the blocks of the organizations they are affiliated to. The dashed links stand for the affiliations.

  The networks are of sizes: n O = 60 and n I = 180.

Figure 2 . 4 -

 24 Figure 2.4 -Clustering and model selection for 3 different topologies on the interindividual level, varying and density d. Each situation is simulated 50 times. A: ARI for the inter-individual level, comparing the model used for inference. B: Stacked frequency barplot of the selected number of blocks for the inter-individual level in the MLVSBM (in blue). C: Stacked frequency barplot of the selected number of blocks for the inter-individual level chosen in the SBM (in red).

Figure 2 . 5 -

 25 Figure 2.5 -Clustering and model selection for 3 different topologies on the interindividual level, as function of δ and density d. Each situation is simulated 50 times. The yellow vertical lines represent a δ = 1/3 (i.e. a γ with uniform coefficients, resulting into independence between the two levels). A: ARI for the inter-individual level, comparing the model used for inference. B: Stacked frequency barplot of the selected number of blocks for the inter-individual level in the MLVSBM. C: Stacked frequency barplot of the selected model with respect to inter-level dependence.

  The data were collected by face-to-face interviews. At the individual level, people were asked to select from a list the individuals from which they obtain advice or information during or before the trade fair. The level consists of 128 individuals and 710 directed interactions (density = 0.044). The individuals were affiliated to 109 organizations, each one containing from one to six individuals. At the interorganizational level, two kinds of interactions were collected: a deal network (deals signed since the last trade fair) and a meeting network (derived from the aggregation at the inter-organizational level of the meetings planned by individuals on the trade fair's website). Both networks are symmetric with respective densities 0.067 and 0.059.

Figure 2 . 6 -

 26 Figure 2.6 -AUC of the prediction for A: missing dyads, B: missing links, in function of the missing proportion for the inter-individual level. Colors represent different network at the inter-organizational level. None (beige) is equivalent to a single layer SBM on the individuals. The confidence interval is given by mean ± stderror.

Figure 2 . 7 -

 27 Figure 2.7 -Multilevel network of the Promoshow East trade fair 2011. Above: the deal network for the organizations and below: the advice network for the individuals. A: Mesoscopic view of the multilevel network. Nodes stand for the blocks, donut charts show the relation between Z O and Z I . Black edges are the probabilities of connection α I and α O , blue edges stand for P(X I ii = 1|Z O A i , Z O A i ), i.e. the probability of interaction between organizations through their individuals. For sake of clarity only edges with probabilities above the density are shown. B: View of the network. The size of a node is proportional to its in-degree. Colors represent the clustering obtained with the MLVSBM. C: Matrix representation of the multilevel network. At the bottom-left, the adjacency matrix of the advice network between individuals, at the top-right, the deal network between organizations, at the top-left, the affiliation matrix of the individuals to the organizations. Entries are reordered by block from left to right and bottom to top. Blocks are separated by thin lines and levels by thick lines. The entries of the bottom-right matrix are the parameters α I , γ and α O multiplied by 100.

Furthermore, our model

  is able to decide about the independence of the structure of connections of the two levels. This is done by a model selection criterion. It would be interesting to test (in a statistical meaning) this independence but we know that the variance of our estimators is underestimated because of the variational approach (see[START_REF] Blei | Variational inference: A review for statisticians[END_REF] for a review). Besides, sociological studies stated that some individuals benefit more than others from their organization's interactions[START_REF] Lazega | Multilevel network analysis for the social sciences: Theory, methods and applications[END_REF], which could lead us to consider more local independence between levels. For multiplex networks, De Bacco et al. (2017) use dyad predictions as a way to define interdependence between layers while Stanley et al. (2016) make a clustering of layer by aggregating the most similar. Our work considers multilevel networks where each level has nodes of different natures and Figure 2.6 shows that the dependence between levels leads to a better recovery of missing information. This can be used to help data collection or to correct spurious information on existing data as suggested in Clauset et al. (2008) or Guimerà and Sales-Pardo (

  .B.15) For k ∈ {1, . . . , Q O + 1}, we define δ k as δ k = Det(M O -k ) where M O -k is the square matrix corresponding to M O without the k-th row. Let B O be the polynomial function defined as:

  where U IO is completely defined by P X,θ and the other terms have been identified before. Thus γ = (RI ) -1 U IO (R O ) -1 D -1π O and γ is identified. A Stochastic Block Model for the Analysis of Multilevel Networks

  Model for the Analysis of Multilevel NetworksLet Θ = Π O × A I × A O × Γ be the space of the model parameters. We set a prior distribution on θ:p(θ|Q I , Q O ) = p(γ|Q I , Q O )p(π O |Q O )p(α I |Q I )p(α O |Q O ) where p(π O |Q O )is a Dirichlet distribution of hyper-parameter (1/2, • • • , 1/2) and p(α I |Q I ) and p(α O |Q O ) are independent Beta distributions.

  .D.25) This approximation results from a BIC-type approximation of log α O (X O | Z O , Q O ) and a Stirling approximation of log π O ( Z O , Q O ). The same BIC-type approximation on log α I (X I | Z I , Q I ) (Equation (2.D.22)) leads to:

  .D.27) The quantity (2.D.27) evaluated at (Z I , Z O ) := ( Z I , Z O ) can be reformulated in the following way:

Figure 2 . 8 -

 28 Figure 2.8 -DAG of the generalized Stochastic Block Model for Multilevel Network (gMLVSBM)

  set.seed(123) my_mlvsbm <-MLVSBM::mlvsbm_simulate_network( n = list(I = 60, O = 40), # Number of nodes for the lower level # and the upper level Q = list(I = 3, O = 3), # Number of blocks for the lower level a # and the upper level pi = c(.5, .3, .2), # Block proportion for the upper level, must sum to one gamma = matrix(c(.8, .1, .1, # Block proportion for the lower level, .1, .8, .1, .1, .1, .8), # each column must sum to one nrow = 3, ncol = 3, byrow = TRUE), alpha = list(I = matrix(c(.1, .1, .3, .1, .2, .5, .1, .5, .5), nrow = 3, ncol = 3, byrow = TRUE), # Connection matrix O = matrix(c(.5, .1, .1, .1, .5, .1, .1, .1, .5), nrow = 3, ncol = 3, byrow = TRUE)),# between blocks directed = list(I = TRUE, O = FALSE), # Are the upper and lower level # directed or not ? affiliation = "preferential", # How the affiliation matrix is generated no_empty_org = FALSE) # May the affiliation matrix have column suming to 0The network is stocked in an R6 object of type MLVSBM. Now, we create a multilevel network object from 2 existing adjacency matrix and an affiliation matrix. The lower level correspond to the inter-individual level while the upper level is the inter-organizational level: lower_level <-my_mlvsbm$adjacency_matrix$I # matrix of size nI x nI upper_level <-my_mlvsbm$adjacency_matrix$O # matrix of size nO x nO affiliation <-my_mlvsbm$affiliation_matrix # matrix of size nI x nO my_mlvsbm2 <-mlvsbm_create_network(X = list(I = lower_level, O = upper_level), A = affiliation)

  print(fit) #> Multilevel Stochastic Block Model --bernoulli variant #> ===================================================================== #> Dimension = ( 60 40 ) -( 3 3 ) blocks. #> ===================================================================== #> * Useful fields #> $independent, $distribution, $nb_nodes, $nb_clusters, $Z #>$membership, $parameters, $ICL, $vbound, $X_hat # plot(fit, type = "matrix") coef(fit) #> $alpha #> $alpha$I #>2.F. MLVSBM packageTutorial 85 #> [3,] 0.18200998 0.76913196 2.105228e-06 pred <-predict(fit) pred$nodes$O #>O1 O2 O3 O4 O5 O6 O7 O8 O9 O10 O11 O12 O13 O14 O15 O16 O17 O18 O19 O20 #O23 O24 O25 O26 O27 O28 O29 O30 O31 O32 O33 O34 O35 O36 O37 O38 O39 O40 #0.000 0.094 0.094 0.231 0.094 0.538 0.231 0.538 0.231 0.094 0.231 0.094 #> I2 0.096 0.000 0.134 0.096 0.134 0.284 0.096 0.284 0.096 0.134 0.096 0.134 plot(fit, type = "matrix"))

  model with index the highest ICL my_fit <-my_mlvsbm$fittedmodels[[which.max(my_mlvsbm$ICL$ICL)]] # A fitted SBM for the lower level with 3 blocks my_sbm_lower <-my_mlvsbm$fittedmodels_sbm$lower[[3]] # A fitted SBM for the upper level with 2 blocks my_sbm_upper <-my_mlvsbm$fittedmodels_sbm$upper[[2]] You can also get the parameters and the clustering of the fitted model from the FitMLVSBM object as follows: fit$parameters # The connectivity and membership parameters of the model #> $alpha #> $alpha$I A Stochastic Block Model for the Analysis of Multilevel Networks

  vector of the varational bound of the VEM algorithm #> [1] -2088.490 -2088.447 -2088.447 -2088.447 tau <-fit$membership # The variational parameters of the model pred <-fit$X_hat # The links predictions for each level 2.G. Hard to Infer Levels: Benefits of the Multilevel Modeling library(MLVSBM) library(aricode) library(dplyr) library(ggplot2) library(tidyr) library(pbmcapply)

  alpha <-list() alpha$I <-matrix(c(.1, .21, .21, .1), 2, 2) alpha$O <-matrix(c(.29, .1, .1, .29), 2, 2) Then simulate 50 networks for each value of γ. Let recall that γ is the mixture parameter for the block membership of the individuals given the one of their A Stochastic Block Model for the Analysis of Multilevel Networks respective organizations, for g ∈ [.5, 1],

  ( X = seq(50L), FUN = function(i) { mlvl <-MLVSBM::mlvsbm_simulate_network( n = n, Q = Q, pi = pi, gamma = gamma, alpha = alpha, directed = list(I = FALSE, O = FALSE)) fit <-MLVSBM::mlvsbm_estimate_network(mlvl, nb_cores = 2L) return(tibble( "SBM_ARI_I" = aricode::ARI( c1 = mlvl$memberships$I, c2 = mlvl$fittedmodels_sbm$lower[[which.max(mlvl$ICL_sbm$lower)]]$Z), "SBM_ARI_O" = aricode::ARI( c1 = mlvl$memberships$O, c2 = mlvl$fittedmodels_sbm$upper[[which.max(mlvl$ICL_sbm$upper)]]$Z), "MLVL_ARI_I" = aricode::ARI( c1 = mlvl$memberships$I, c2 = fit$Z$I), "MLVL_ARI_O" = aricode::ARI( c1 = mlvl$memberships$O, c2 = fit$Z$O))) }, mc.cores = 6L) res <-bind_rows(res) res$g <-as.factor(g) res_detect_thresh <-bind_rows(res_detect_thresh, res) }

144 Motivation

 144 res_detect_thresh %>% pivot_longer(-g, names_to = "Model", values_to = "ARI") %>% ggplot(aes(x = g, y = ARI, group = Model, fill = Model)) + stat_summary(geom = "ribbon", fun.data = "mean_se", alpha = .3) + stat_summary(geom = "line", fun = "mean", col = "black", size = 1..550.[START_REF] Gallagher | A clarified typology of core-periphery structure in networks[END_REF].650.70.750.80.850.90.95 1 0.50.550.60.650.70.750.80.850.[START_REF] Kivelä | Multilayer networks[END_REF].summarise(across(.cols = everything(), ~mean(.x == 1)), .groups = "keep") %>% pivot_longer(-g, names_to = "Model", values_to = "Perfect Recovery") %>% ggplot(aes(x = g, y = Perfect Recovery , group = Model, col = Model, linetype = Model)) + geom_line(size = 1.1) + theme_bw() g, names_to = "Model", values_to = "ARI") %>% ggplot(aes(x = g, y = ARI, group = g, fill = Model).550.[START_REF] Gallagher | A clarified typology of core-periphery structure in networks[END_REF].650.70.750.80.850.90.95 1 0.50.550.60.650.70.750.80.850.90.. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 97 3.2 Data Motivation and the Stochastic Block Model . . . . . . . . . . 3.3 Joint Modeling of a Collection of Networks . . . . . . . . . . . . . . 3.3.1 A collection of i.i.d. SBM . . . . . . . . . . . . . . . . . . . 3.3.2 A collection of networks with varying block sizes . . . . . . . 3.3.3 A collection of networks with varying density (δ-colSBM ) . 3.3.4 Collection of networks with varying block sizes and density (δπ-colSBM ) . . . . . . . . . . . . . . . . . . . . . . . . . . 3.4 Likelihood and identifiability of the models . . . . . . . . . . . . . . 3.4.1 Log-likelihood expression . . . . . . . . . . . . . . . . . . . . 3.5 Variational estimation of the parameters . . . . . . . . . . . . . . . 3.6 Model selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.6.1 Selecting the number of blocks Q . . . . . . . . . . . . . . . 3.6.2 Testing common connectivity structure . . . . . . . . . . . . 3.7 Partition of networks according to their mesoscale structure . . . . 3.8 Simulation studies . . . . . . . . . . . . . . . . . . . . . . . . . . .3.8.1 Efficiency of the inference procedure . . . . . . . . . . . . . 3.8.2 Capacity to distinguish π-colSBM from iid-colSBM . . . . 3.8.3 Partition of networks . . . . . . . . . . . . . . . . . . . . . . 3.8.4 Finding finer block structures . . . . . . . . . . . . . . . . .3.9 Application to Food Webs . . . . . . . . . . . . . . . . . . . . . . . 3.9.1 Joint analysis of 3 stream food webs . . . . . . . . . . . . . Joint inference of a collection of networks 3.9.2 Partition of a collection of 67 predation networks . . . . . . 124 3.10 Discussion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 126 3.A Proof of identifiability . . . . . . . . . . . . . . . . . . . . . . . . . 128 3.B Details of the Model Selection when Allowing for Empty Blocks . . 130 3.C Partition of Food Webs with δcolSBM . . . . . . . . . . . . . . . . 132 3.D Analyze of advice networks . . . . . . . . . . . . . . . . . . . . . . . 133 3.D.1 Presentation of the advice networks . . . . . . . . . . . . . . 133 3.D.2 Pairwise analysis of the advice networks . . . . . . . . . . . 135 3.D.3 Looking for larger collections . . . . . . . . . . . . . . . . . 139 3.D.4 Using dyad prediction to quantify the link between networks 143 3.D.5 Conclusion . . . . . . . . . . . . . . . . . . . . . . . . . . . . Plusieurs idées d'applications ont motivé ce travail. Dans le cadre du groupe de recherche ResoDiv (https://resodiv.cnrs.fr/, groupe interdisciplinaire étudiant des réseaux de circulation d'objets biologiques tels que des plantes ou des animaux), Étienne Polge a exposé des travaux concernant l'analyse des réseaux socio-économiques de collectifs d'agriculteurs et de leur partenaires (Polge and Torre, 2018; Pachoud et al., 2019). Nous nous sommes demandés, dans le cas où les différents réseaux socio-économiques partagent une partie de leurs structures, comment retrouver les agriculteurs ayant le même rôle structurel aux seins des différents collectifs. Parallèlement, au sein de l'ANR Econet, de nombreuses questions se posent autour de la classification et la comparaison d'écosystèmes. Nous proposons dans ce chapitre une méthode pour traiter ces différentes problématiques. Résumé Une collection de réseaux consiste en un ensemble de réseaux qui ne partagent pas de noeuds mais qui décrivent le même type d'interactions observées dans différentes situations ou contextes. Une hypothèse est que les réseaux de la collection partagent une structure commune puisque la nature des interactions est la même. Par exemple, dans le cas d'une collection de réseaux trophiques rassemblés dans différents écosystèmes, on s'attend à ce que certains groupes d'espèces (espèces basales ou superprédateurs, par exemple) présentant des profils similaires de relations trophiques puissent être rencontrés dans tous les réseaux.Nous proposons de nous appuyer sur le populaire modèle à blocs stochastiques (SBM) pour identifier la structure commune dans la collection. Le SBM est un modèle probabiliste qui suppose l'existence de variables latentes représentant les groupes de noeuds (blocs) du réseau et dont les paramètres fournissent une description succincte de la structure du réseau à l'échelle mésoscopique. Nous appelons colSBM notre extension du SBM à une modélisation conjointe d'une collection de réseaux. Les réseaux de la collection sont supposés être des réalisations indépendantes de

nmZθF

  The number of nodes of network m X A collection of M adjacency matrices X m The adjacency matrix of network m of size n m × n m The set of latent variables Z m The blocks memberships of the nodes of network m The set of model parameters τ The set of variational parameters α The set of connectivity parameters π The set of mixture parameters δ The set of density parameters π m The mixture parameters for network m The emission distribution S The support of the blocks of the colSBM , a Q × M binary matrix M A subset of {1, . . . , M }, the indices of a subcollection BIC-L The model selection criterion Q m The set of allowed blocks for network m G A partition of networks NP The number of parameters in the model

  Most contributions about collections of networks rely on some node correspondence between the networks. Recently, motivated by the analysis of fMRI data a few works extend the SBM to model population of networks (Paul and Chen, 2018; Pavlović et al., 2020). Le et al. (2018) make the assumption that the networks of the collection are noisy realizations of the true network, while Reyes and Rodriguez (2016) use in a Bayesian framework a hierarchical SBM to model the collection. Signorelli and Wit (2020) propose a mixture of network models which is not restricted to the SBM. The contributions dealing with networks with no node correspondence include a hierarchical mixed membership SBM, using a common bayesian prior on the connectivity parameter of the different networks (Sweet et al., 2014). Finally on network clustering, Mukherjee et al. (2017) propose to fit a graphon when the networks in the collection have the same number of nodes while they use graph moments when this is not the case.

Figure 3 . 1 -

 31 Figure 3.1 -Matricial view of 3 stream food webs. The species are reordered by blocks and blocks are ordered by expected out-degrees to emulate the trophic levels (bottom to top and right to left). The blocks have been obtained by fitting a SBM on each network separately.

1 . 2 .α 11 α 12 α 13 α 21 α 22 α 23 α 31 α 32 α 33    π 1

 12331 We illustrate the flexibility of this model with three examples, all with Q = 3 and M = 2. First consider the situation where the 3 blocks are represented in the two networks but with different block proportions: α =    α 11 α 12 α 13 α 21 α 22 α 23 α 31 α 32 α 33    π 1 = [.25, .25, .50] π 2 = [.20, .50, .30] . Joint inference of a collection of networks In that case, Now imagine two networks with imbricated structures. Blocks 1 and 3 are represented in the two networks while block 2 only exists in network 1. = [.25, .25, .50] π 2 = [.40, 0 , .60] .

Collection 3 . 4 .

 34 Likelihood and identifiability of the models 105Model name Block prop.Connection param.

  for iid-colSBM and π-colSBM .For the δ-colSBM and δπ-colSBM , there is no closed form for δ and α for a given value of τ . If F = Poisson, then δ and α can be iteratively updated using the following formulae: n m qr αqrIf F = Bernoulli, no explicit expression can be derived and one has to rely on a gradient ascent algorithm to update the parameters at each M-Step.

Collection 3 . 7 .

 37 Partition of networks according to their mesoscale structure 113 share the same connectivity structure if:

3. 8 . Simulation studies 115 Algorithm 5 :

 81155 Clustering a collection of networks into two groups Call: Clust2Coll(X = (X m ) m∈M ) Data: X = (X m ) m∈M a collection of networks and G = {M} the trivial partition in a unique group begin -Fit colSBM on X -Compute the score Sc 0 = Sc(G) -Compute the dissimilarity for all the networks in the collection D M (m, m ) m,m ∈M -Apply a 2-medoïds algorithm to obtain G 1 and G 2 giving a partition of M. -Compute Sc * = Sc(G * ) where

3 Collection 3 . 8 .

 338 For iid-colSBM , π-colSBM and δ-colSBM and δπ-colSBM , we simulate M = 9 undirected networks with 60 nodes and Q = Simulation studies 119 blocks. The block proportions are chosen as follows: π 1 = (.2, .3, .5)

Figure 3 . 2 -

 32 Figure 3.2 -Partition of networks. ARI of the recovered partition of networks.Orange is for the iid-colSBM , green for the δ-colSBM , purple for the δπ-colSBM and yellow for the π-colSBM .

Collection

3. 9 . 121 Figure 3 . 3 -

 912133 Figure 3.3 -Finding finer block structures. Cumulative barplot of Q by the SBM s (blue) and the adequate colSBM (red) under the different simulation scenario. The number of blocks to be recovered is 3 and the darkest shade corresponds to Q = 3.

  2 at page 101, we fitted sep-SBM obtained 5 blocks for Martins, 3 blocks for Cooper and 4 blocks for Herlzier. For reminder, a matricial representation of the block reordered food webs was shown in Figure3.1. Each food web comprises of 2 blocks of basal species (the 2 bottom blocks).

Finding a common structure

  between the networks We now fit the four colSBM models in order to find a common structure among the 3 networks. First, notice that our model selection criterion greatly favors common network structure above separated one: BIC-L = -2080 for sep-SBM versus respectively -1966, -1982, -1969 and -1989 for iid-colSBM , π-colSBM , δ-colSBM , δπ-colSBM . The structures of the collection under the different models are represented in Figure 3.4. In this figure, the square matrix represents the estimated connection matrix α, while the cumulative bar plot on the right represents the π m (see definition page 114). Joint inference of a collection of networks

3. 9 . 123 Figure 3 . 4 -

 912334 Figure 3.4 -Estimated structure of the collection of 3 stream food webs with the four colSBM models.For each network, the matrix on the left is the estimated parameter connectivity α, the barplot on the right depicts π(m) . The ordering is done by trophic level from bottom to top and right to left. For (δ-δπ)colSBM s we give δ below the barplot.

Figure 3 . 5 -

 35 Figure 3.5 -Prediction of missing links and NA entries on stream food webs.

Figure 3 . 6 -

 36 Figure 3.6 -Above: Classification and connectivity structures of a collection of 67 predation networks from the Mangal database into 5 groups. The length of the dendrogram is given by the difference in BIC-L to the best model. Below: Contingency table of the classification found by πcolSBM and the different datasets from the Mangal database.

  δ) π S p(X|Z, α S , δ, S)p(Z|π S , S)p(α S , δ)p(π S )d(α S , δ)d(π S ) = (α S ,δ) p(X|Z, α S , δ, S)p(α S , δ)d(α S , δ) B1 π S p(Z|π S , S)p(π S )d(π S ) B2 , (

For

  B2, we use a Q m -dimensional Dirichlet prior for each π m S : Collection 3.B. Details of the Model Selection when Allowing for Empty Blocks 131

Figure 3 . 7 -

 37 Figure 3.7 -Above: Classification and connectivity structures of a collection of 67 predation networks fron the Mangal database into 3 groups. The length of the dendrogram is given by the difference in BIC-L to the best model. Below: Contingency table of the classification found by δcolSBM and the different datasets from the Mangal database.

  The individuals involved are judges(Lazega et al., 2011), lawyers[START_REF] Lazega | The collegial phenomenon: The social mechanisms of cooperation among peers in a corporate law partnership[END_REF], priests[START_REF] Lazega | Two definitions of collegiality and their inter-relation: The case of a roman catholic diocese[END_REF] and researchers[START_REF] Lazega | Catching up with big fish in the big pond? multi-level network analysis through linked design[END_REF]. Using this collection of networks, Lazega and Brailly (2021) analyze and compare the homophily of the different types of actors. The 4 networks are heterogeneous in size and density, with the lawyers advice network having between 2 to 3.5 times the density of the other networks: n = (153, 71, 104, 126) and d = (.053, .179, .049, .061).

  We show on a collection of advice networks how considering a joint model on the networks leads to changes on the structure explaining the connection in the networks and how information contained in other networks might help the prediction of the Collection 3.D. Analyze of advice networks 145 interactions on a given network.

DiffusionZ

  Le contenu de ce chapitre ainsi que la première annexe ont fait l'objet d'un article (Chabert-Liddell et al., 2022) publié dans le journal Environmetrics. Un package R nommé robber, disponible sur le CRAN (Chabert-Liddell, 2021b), dont la documentation est disponible à l'adresse suivante https://Chabert-Liddel l.github.io/robber/, permet d'appliquer les méthodes développées ci-dessous. Un exemple d'application du package à la comparaison de la robustesse d'une collection de réseaux d'interactions écologiques bipartites est donné en appendice 4.B. Notations for this chapter n r The number of row species n c The number of column species A An incident matrix of size n r × n c The block membership of row species W The block membership of column species Q r The number of row blocks Q c The number of column blocks δ The connectivity parameter, a matrix of size Q r × Q c π The mixture parameter of row species ρ The mixture parameter of column species θ The set of parameters (δ, π, ρ) R The robustness function of the network R The robustness statistic of the network A A probability distribution of networks S A probability distribution of primary extinction sequences U A uniform probability distribution of primary extinction sequences B A probability distribution of primary extinction sequences by block memberships (B ↑ increasing, B ↑ decreasing) D A probability distribution of primary extinction sequences which depends on the sequence of the degrees (D ↑ increasing, D ↓ decreasing) D ↑ ord A probability distribution of primary extinction sequences determined by the increasing (D ↓ ord , decreasing) sequence of the degrees D ↑ lin A probability distribution of primary extinction sequences which depends linearly on the increasing (D ↓ lin , decreasing) sequence of the degrees

1

 1

4. 1 .

 1 Introduction 151

  which may bias the computed network statistics (Rivera-Hutinel et al., 2012; de Manincor et al., 2020) such as the robustness. The stochastic block model (SBM Nowicki and Snijders, 2001) and its extensions for bipartite networks, such as the biSBM (Govaert and Nadif, 2003, also referred to as Latent Block Model) or its degree corrected counterpart (DCbiSBM Larremore et al., 2014) have gained a lot of attention in the statistical and network science research

  , S (b) , m) where S (b) ∼ i.i.d S, b = 1, . . . , B. (4.3) The robustness statistic of a network A and a primary extinction sequences distribution S is defined as: R S (A) = 1 n r nr m=0 R S (A, m), (4.4) which corresponds to the area under the curve (AUC) of the robustness function where the x-axis has been re-normalized to match with the proportion of removed row species. R S (A) is the Monte Carlo version of R S (A).

. 5 )

 5 α = 0 coincides to the uniform distribution U while, if α = 1, the primary extinction sequence depends linearly on the degrees. The increasing order is obtained by reversing this sequence of primary extinction. Remark. The R S (A, m)'s computed for the first two S's described above are the most widely used. They are implemented in the R package bipartite (Dormann et al., 2008) available on cran. The robustness function (4.2) and corresponding statistic (4.4) are then computed from a unique observed network A and a probability distribution S conditional to A (through the row degrees): R S (A, m) = E S|A [R(A, S, m)] with S|A ∼ S . (4.6)

Proposition 4 . 1 .

 41 Let (A, S) ∼ L θ,n,U and set δ +q = Qr k=1 π k δ kq . Then, • ∀m = 1, . . . , n r : R θ,n,U (m) = 1 -Qc q=1 ρ q (1 -δ +q ) nr-m , (4.12)

R

  θ,n,U = 1 n r nr m=0 R θ,n,U (m) = 1 -1 n r Qc q=1 ρ q (1 -δ +q ) -(1 -δ +q ) nr+1 δ +q . (4.13) Robustness of bipartite ecological networks Proof. Since (A, S) ∼ L θ,n,U ,

kA

  m+1:nr ∈{1,...,Qr} nr -m ij = 0|Z m+1:nr = k m+1:nr , W j = q   × P (Z m+1:nr = k m+1:nr , W j = q) = k m+1:nr ∈{1,...,Qr} nr -m

. 14 )

 14 where min + is the positive part of the minimum function: min + (x, y) = max(0, min(x, y)). The proof of Proposition 4.2 is provided in the Appendix 4.A. The robustness statistic R θ,n,B is the mean of the R θ,n,B (m)'s: no simplified expression has been obtained. Note that, if Q r = 1 or if δ kq = d, then R θ,n,B (m) = R θ,n,U (m).

Figure 4 . 1 ,

 41 we illustrate the variations of the robustness function for a given structure encoded in θ = δ = .4 .15 .25 .05 , π = (0.25, 0.75), ρ = (0.2, 0.8) . This corresponds to a so-called core-periphery structure where the first blocks (in rows and columns) are well connected (the core) and the second blocks are less connected (the periphery). We represent the functions m → R θ,n,S (m) with S = U and S = B such that the blocks are ordered by decreasing or increasing connectivity (solid black lines in Figure 4.1). For the uniform distribution, we also plot the area given by m → R θ,n,U (m) ± 2 V A (R U (A, m)) (grey ribbon). The colored dotted lines are Monte Carlo estimates of the robustness functions R S (A, m) corresponding to 10 simulated networks for the same extinction sequence distributions. The Monte Carlo estimates are computed over 300 realizations of extinction sequences. The inflection points and the dispersion of the dotted lines observed respectively around an extinction rate of 0.25 for decreasing extinction and 0.75 for increasing extinction correspond respectively to the proportion of the core or the periphery blocks.

Figure 4 . 1 -

 41 Figure 4.1 -Robustness function computed from a set of biSBM parameters (plain black) and by Monte Carlo for 10 networks generated from the same biSBM distribution (dotted) for block decreasing, uniform and block increasing primary extinction sequences. The grey ribbon on the uniform facet is twice the standard error given in Proposition 4.3.

Properties 4. 1 . 1 .

 11 Under the joint distribution L θ,n,S where S ∈ {U, B}, the following properties hold: (a) the function m ∈ {0, . . . , n r } → R θ,n,S (m) is a strictly decreasing function provided that δ k+ > 0 for all k > 0, (b) R θ,n,S (0) ≤ 1 -(1 -d) nr ≤ 1 where d = k,q π k ρ q δ kq , (c) For θ = (π, ρ, δ) and θ = (π , ρ , δ ) such that π = π , ρ = ρ and ∀(k, q) ∈ {1, . . . , Q r } × {1, . . . , Q c } δ kq ≤ δ kq , we have ∀m ∈ 0, . . . , n r , R θ,n,S (m) ≤ R θ ,n,S (m) and R θ,n,S ≤ R θ,n,S . 2. Under the joint distribution L θ,n,U , if n r ≤ n r then R θ,(nr,nc),U < R θ,(n r ,nc),U . Proof. Property 1.(a) comes from the robustness definition and from the fact that s(m + 1 : n r ) ⊂ s(m : n r ) for any extinction sequence s. Property 1.(b) is a consequence of Proposition 4.4. Property 1.(c) is true for all m ∈ {0, . . . , n r } from Equations (4.12) and (S-4.19). For Property 2., first notice that R θ,(nr+1,nc),U (m + 1) = R θ,(nr,nc),U (m). Then, nr+1,nc),U (0) + n r R θ,(nr,nc),U (Property 1.(a)) > 1 n r + 1 R θ,(nr,nc),U (0) + n r R θ,(nr,nc),U > 1 n r + 1 R θ,(nr,nc),U + n r R θ,(nr,nc),U = R θ,(nr,nc),U Properties 1.(a) and 1.(b) supply a bound depending on the expected density and the number of row species n r . Property 1.(d) implies that for a given block structure, the robustness increases when each element δ kq increases while Property 2.

Proposition 4 . 4 .

 44 Upper bound of robustness under L θ,n,U . 1. For all m ∈ {0 . . . , n r }: R θ,(nr,nc),U (m) ≤ 1 -(1 -d) nr-m . 2. For all m ∈ {0 . . . , n r -2} arg max θ∈Θ d R θ,(nr,nc),U (m) =    θ : Qr k=1 π k δ kq = Qr k=1 π k δ kq , ∀(q, q ) ∈ {1, . . . , Q c } 2    := Θ max d,nr , 4.5. Impact of the Network Structure on the Robustness 163 Moreover, ∀θ ∈ Θ d and ∀n c : R θ,(nr,nc),U

Figure 4

 4

Figure 4 . 2 -

 42 Figure 4.2 -Density curve of the distribution of the expectation of the robustness statistic under biSBMs of the same size and density with three different sets of parameters. Each network is simulated from a given set of parameters, then the robustness is computed by the Monte-Carlo approximation given in (4.4). 500 simulations each.

Fig. 4 .

 4 3. ) no matter S. On the other hand, core-periphery structure with small core that are highly connected to the whole network have the strongest impact on the robustness, negatively when S = B ↓ and positively when S = B ↑ (Fig.4.3. ). The effect of this structure ( ) is very slight on uniform extinction sequences whereas the effect tends to get larger when the blocks' sizes are more balanced (Fig.4.3. ).

Figure 4 . 3 -

 43 Figure 4.3 -Robustness for different biSBM topologies. Primary extinction sequences are displayed in rows and topologies in columns.In abscissa, j is a topology strength parameter. rho is the proportion of column species that belongs to the first column block. • represents a topology with no structure (Erdős-Rényi (ER)). Color gradient varies from blue (less robust than an ER), to white (as robust as an ER), to red (more robust than an ER). The symbols corresponds to the following mesoscale structures:-large core, strongly connected only to itself, -small core, strongly connected to the whole network, -medium size core strongly connected only to itself, -highly modular with unbalanced blocks' sizes, ♦ -highly modular with slightly smaller highly connected blocks, -highly modular with slightly larger highly connected blocks.

Figure 4 . 4 -

 44 Figure 4.4 -Expected robustness statistic (R θ,n,U ) under a biSBM (circles) and DCbiSBM (purple triangles) as a function of the standard robustness ( R U (A)) for uniform extinction sequences. The grey to red gradient stands for (1 -d) nr , the probability to have an empty column under an Erdős-Rényi distribution. The size of the point is related to Z R (A).

  ) and the one where the nodes are weighted by a linear function of the degrees as in Equation (4.5) with α = 1 ( R D ↑ lin (A) and R D ↓ lin (A)). We examine the fit with R θ,n,S where S ∈ {B ↓ , B ↑ } mimics the degree increasing and decreasing extinction sequences. The comparison are plotted in Figure 4.5. When considering primary extinction sequences by decreasing connectivity, there is a positive bias of R θ,n,B ↓ on R D ↓ ord (A) (top-left) which is attenuated when considering R D ↓ lin (A) (bottom-left). For primary extinction sequences by increasing connectivity, the empirical robustness is highly dependent on the degrees of the most connected species, hence the fit of R θ,n,B ↑ on R D ↑ ord (A) is very poor with a negative bias (top-right). While the negative bias still remains, the fit on R D ↑ lin (A) is correct for a much higher fraction of the networks (bottom-right).

Figure 4 . 5 -

 45 Figure 4.5 -R θ,n,S as a function of the classical robustness R D (A) for various S. Block Decreasing (resp. increasing) = B ↓ (resp B ↑ ), Ordered Decreasing (resp. Increasing) = D ↓ ord (resp. D ↑ ord ). Linear Decreasing (resp. Increasing) = D ↓ lin (resp. D ↑ lin ). The grey to red gradient stands for (1 -d) nr , the probability to have an empty column under an Erdős-Rényi distribution. The size of the point is the deviation between the biSBM and the empirical robustness in terms of the number of standard deviations of the robustness under a biSBM distribution for S = U.

Figure 4 . 6 , 30 b=1(

 4630 we computed the root mean squared error (RMSE) for each network and for different cases (in terms of observation process and extinction sequence) between the robustness computations on the true network (fully observed) and on the partially observed network. When the method for computing the robustness is based on MC computations, we considered the uniform primary extinction sequences (named Monte Carlo in Fig.4.6) and the increasing and decreasing extinction sequences that depend strictly (named Ordered Monte Carlo in Fig. 4.6) or proportionally as in Equation (4.5) (named Linear Monte Carlo in Fig. 4.6) on the row degrees. More specifically, the RMSE for the methods based on MC computations are computed for any extinction sequences S = {U, D ↑ ord , D ↑ lin , D ↓ ord , D ↓ lin } listed above, as: 1 30 RS (A) -RS ( Ãb )) 2

Figure 4 . 6 -

 46 Figure 4.6 -Error (RMSE) in the prediction of the robustness of 98 fully observed networks computed from partially observed networks. On the left, 12.5% of possible interactions are recoded as NA. and on the right, 25% of species are missing.

Proposition 4 . 2 . 1 +

 421 Let (A, S) ∼ L θ,n,B , thenR θ,n,B (m) = 1 -•••+n Qr =nr n r ! n 1 ! . . . n Qr ! Qr k=1 π n k k (1 -α kq ) min + (n k , l≤k n l -m), (S-4.[START_REF] Bollobás | A probabilistic proof of an asymptotic formula for the number of labelled regular graphs[END_REF]) where min + is the positive part of the minimum function: min + (x, y) = max(0, min(x, y)).

Eπ 1 :( 1 -

 11 (A,S) [R(A, S, m)] nr E (A,S) [R(A, S, m)|Z 1:nr = k 1:nr , W 1:nc = q 1:nc ] A S(i)j )|Z 1:nr = k 1:nr , W j = q = s | Z 1:nr = k 1:nr )

( 1 -( 1 -α kq ) nr i=m+1 1

 111 α kq ) 1 {k s(i) =k} = Qr k=1 {k s(i) =k} , with for all s such that k s(1) ≤ • • • ≤ k s(nr) : nr i=m+1 1 {k s(i) =k} = n l ≤ m, l≤k n l -m if l≤k n l -n k < m < l≤k n l , n k if m ≤ l≤k n l -n k .

( 1 -( 1 -( 1 -Proposition 4 . 3 .

 11143 = s |Z 1:nr = k 1:nr ) nr i=m+1 α k s(i) q ) = s∈Sn r P(S = s | Z 1:nr = k 1:nr ) Qr k=1 α kq ) min + (n k , l≤k n l -m) α kq ) min + (n k , l≤k n l -m) .(S-4.21)Inputting Equation (S-4.21) in Equation (S-4.20), we obtain the result:E (A,S) [R(A, S, m)] = 1 -Qc q=1 ρ q n 1 +•••+n Qr =nr n r ! n 1 ! . . . n Qr ! × Qr k=1 π n k k (1 -α kq ) min + (n k , l≤k n l -m) . Let A ∼ biSBM (θ, n), η q = 1 -α +q and η qq = Qr k=1 π k (1α kq )(1 -α kq ).

Combinatorial lemma 4 . 1 .

 41 Let m, m the first terms of two permutations of S n , the the proportion of couple of permutation (s, s ) that have exactly l unique terms is:#{(s, s ) : s(1 : m) ∪ s (1 : m ) = l} #(S n , S n ) =    ( m m+m -l )( n-m l-m ) ( n m ) if max{m, m } ≤ l ≤ min{m + m , n}0 otherwise , where s(1 : m) = {s(1), . . . , s(m)}.

Those m terms can

  be reordered into m ! possible arrangements and the n -m resting terms into n -m ! permutations, giving:# {(s, s ) : s(1 : m) ∪ s (1 : m ) = l} = n! m m + m -l n -m l -m m !(n -m )!We then divide by the (n!) 2 couple of permutations possible. #{(s, s ) : s(1 : m) ∪ s (1 : m ) = l} #(S n , S n )

V 2 .E A 1 -

 21 A ( E S [ R(A, S))|A ] ) = E A [ E 2 S [ 1 -R(A, S)|A ] ] B -E 2 A [ E S [ 1 -R(A, S)|A ] ] C (S-4.22)Using Equation (4.12) and Equation (4.4), we have:C = 1 nr nr m=0 Qc q=1 ρ q η nr-m qWe divide B into 2 terms, based on the column index:B = E A ( 1 -E S [ R(A, S, m)|A] • E S [ 1 -R(A, S, m )|A] !n r ! s,s ∈Sn r E A n r ! s,s ∈Sn r E A

π k 1

 1 :nr i∈s(m+1:nr)\s (m +1:nr)(1 -α k i q )i∈s (m +1:nr)\s(m+1:nr)(1 -α k i q ) i∈s(m+1:nr)∩s (m +1:nr) (1 -α k i q )(1 -α k i q ) (Lem.4.1) = l m m+m -l n-m l-m n m q,q ρ q ρ q η l-(nr-m ) q η l-(n-m) q η 2n-m-m -lqq 4.B. Comparing the robustness of bipartite ecological networks with different interaction types 179

i∈s( 1 :q

 1 nr -m)∪s (1:nr -m )A ij =0} |Z 1:nr = k 1:nr , W j = q = 1 n r !n r ! s,s ∈Sn r q ρ q k 1:n π k 1:n i∈s(1:nr-m)∪s (1:nr-m ) (1 -α k i q )Finally we use the symmetry between m and n r -m and input first B1 and B2 into Equation (S-4.23) then B and C into Equation (S-4.22) to obtain the variance of the robustness statistic.To obtain the variance of the robustness function, we fix m, and set m = m in Lemma 4.1, and Equation (S-4.23).

  . Comparing the robustness of bipartite ecological networks with different interaction types 185 the robber package as follows:

1 1

 1 De plus, la dépendance et les changements de structure de connexion gagneraient à être considérés de manière plus locale. Je propose ci-dessous quelques pistes incorporant ces notions pour analyser des réseaux multi-omiques.Modélisation d'une collection de réseaux multi-omiquesAccroître la vitesse et l'efficacité de la sélection végétale par l'utilisation de données omiques est l'un des impératifs pour résoudre les problèmes alimentaires dans le cadre du changement climatique[START_REF] Scossa | Integrating multi-omics data for crop improvement[END_REF]. La prédiction génomique, qui met en relation le génome et le phénotype, permet de rationaliser la sélection végétale. En outre, l'utilisation d'autres données omiques telles que le métabolome, l'ionome et le transcriptome peut non seulement améliorer la précision de la prédiction, mais aussi révéler les mécanismes génétiques et physiologiques qui sous-tendent la prédiction. L'étude de la structure des relations entre les éléments de différentes couches omiques, comme l'ionomique et la métabolomique, peut fournir des indices pour comprendre les mécanismes à l'origine des prédictions. Dans la suite, je propose une nouvelle méthodologie adéquate pour analyser ces données omiques internes et identifier où des changements significatifs dans leur structure se produisent en modélisant l'influence génétique et environnementale sur la structure du réseau. Un réseau multi-omique peut se modéliser par un SBM pour réseaux multipartites (Bar-Hen et al., 2020) permettant de définir l'existence d'une classification spécifique entre les noeuds d'un réseau. Par exemple, il est possible de s'assurer que les noeuds ionomiques et métabolomiques n'appartiennent pas au même bloc, ce qui est adapté à la modélisation des réseaux inter-et intra-multi-omiques. Je souhaite étendre ce modèle au cas d'une population de réseaux multiomiques où le comportement des différents blocs dépend de covariables environnementales (stress de sécheresse. . .) et phénotypiques. Comme proposé par Pavlović et al. (2020) pour des données d'imagerie IRMf, dans le cadre d'un SBM, il est possible d'identifier les blocs dont le comportement change en réponse à ces covariables.Plus formellement, je propose le modèle suivant. Soit {X 1 , . . . , X M }, une collection de réseau multi-omiques. Chaque réseau indicé par m ∈ {1, . . . , M } est composé de n m noeuds répartis en K groupes représentant les couches omiques. On fait l'hypothèse que la correspondance des noeuds entre les réseaux est connue et que la répartition des noeuds dans les groupes est la même pour chaque réseau. Alors, pour tout k ∈ {1, . . . , K},P(Z k i = q) = π q , ∀i ∈ {1, . . . , n}, q ∈ Q k = {1, . . . , Q k }, tel que q∈Q k π q k = 1.Le réseau m est composé d'une suite de matriceX m,k,k , où (k ≤ k ) ∈ K ⊂ {1, . . . ,K} 2 indiquent les différents types de relations omiques d'intêret. Soit e m , le vecteur de taille p e des covariables environnementales et p m , le vecteur de taille p p des covariables phénotypiques du réseau m, alors la loi d'une arête conditionnellement à l'appartenance des noeuds aux blocs suit un modèle de régression logistique pour tout (i = j) ∈ {1, . . . , n} 2 :P(X m,k,k ij = 1|Z k i = q, Z k j = r) = α m,k,k qr , (q, r) ∈ Q k × Q k ,où les covariables peuvent agir à différents niveaux de précision sur la connectivité des réseaux.De manière la plus générale, on introduit de l'hétérogénéité dans la régression en faisant dépendre les paramètres de régression des blocs : α m,k,k qr = + exp -(e mβ k,k qr + p mγ k,k qr + δ k,k q,r ) , où β (resp. γ) est le vecteur des paramètres de la régression pour les covariables environnementales (resp. phénotypiques) et δ est un facteur constant à tous les réseaux.

Lien entre robustesse et

  autres caractéristiques du réseau Ce type d'analyse peut-être étendu à d'autres indices communément utilisés pour analyser des réseaux. Toujours dans le cadre des réseaux d'interactions écologiques bipartites, Vanbergen et al. (2017) relient, une fois l'effet du nombre d'espèces corrigé, la robustesse de réseaux plantes-pollinisateurs à l'emboîtement, au degré de spécialisation des espèces, à la vulnérabilité du réseau (nombre d'insectes visitant chaque espèce de plantes). . .. Trouver, à la manière des travaux sur la robustesse du chapitre 4, une expression de ces différents indicateurs sous des modèles de graphes probabilistes, permettrait toujours suivant ces modèles de relier ces différents indices à la structure du réseau et de comprendre comment ils évoluent les uns par rapport aux autres en fonction de cette structure.

j

  (m) > 0}, l'indicatrice de l'évènement de non extinction de l'espèce k de la troisième couche après m extinctions primaires, par indépendance des extinctions secondaires, P (X,S) (S Dans le cadre d'un SBM tripartite, ces probabilités sont calculables et ne dépendent que des paramètres du modèle comme pour le SBM bipartite. Nous pouvons alors, comme pour les réseaux bipartites, utiliser la robustesse par SBM tripartite pour étudier le lien entre la structure des réseaux et sa robustesse ou bien corriger la robustesse de réseau partiellement observé.Concernant ce dernier point, la qualité de la correction dépend de la manière de redresser les paramètre du SBM. La méthode que nous avons utilisée dans le cadre des travaux sur la robustesse est naïve (nous avons supposé que les espèces manquantes étaient réparties uniformément entre les blocs et que nous observions une proportion constante des interactions dans chaque bloc du réseau). La thèse d'Emré Anakok, en cours à MIA Paris, porte sur l'estimation des paramètres du SBM à partir de réseauxConclusionConclusions et perspectives 191 incomplets, ce qui permettrait de redresser les paramètres du modèle de manière plus réaliste, et donc d'améliorer notre méthode d'estimation de la robustesse.Titre : Apprentissage statistique de collections de réseaux avec applications en écologie et en sociologie Mots clés : Réseaux, Graphes aléatoires, Données hétérogènes, Modèle à blocs stochastiques, Méthodes variationnelles, Apprentissage non supervisé Résumé : Cette thèse porte sur le développement de méthodes statistiques pour l'analyse de collections de réseaux d'interactions à travers trois contributions originales. Les réseaux d'interactions constituent une façon naturelle de représenter sous forme de graphe les échanges ou relations existant entre un ensemble de noeuds représentant des espèces ou des individus. Considérer des collections de réseaux permet d'étudier des systèmes hétérogènes, composés de plusieurs sortes d'interactions impliquant différents types de noeuds. Lorsque les différents réseaux de la collection sont liés par une relation hiérarchique, nous parlerons de réseaux multiniveaux. Le modèle à blocs stochastiques a prouvé sa pertinence pour modéliser l'hétérogénéité du comportement des noeuds dans un unique réseau. Des extensions aux collections de réseaux et aux réseaux multiniveaux sont proposées. Elles permettent d'obtenir un clustering des noeuds des réseaux en fonction de leur rôle dans l'écosystème ou le système social, et de résu-mer la structure du système à l'échelle mésoscopique à travers un faible nombre de paramètres. L'inférence de ces modèles est complexe et des méthodes variationnelles sont adaptées à cette fin. Des méthodes de sélection de modèles permettent également de déterminer la dépendance entre les niveaux pour les réseaux multiniveaux et la similarité entre les structures pour les collections de réseaux. Une dernière partie de cette thèse propose une nouvelle méthode pour étudier la robustesse de réseaux d'interactions écologiques. Chaque réseau est modélisé par un modèle probabiliste dont les paramètres représentent la structure du réseau. Cela permet de faire le lien entre la structure de l'écosystème et sa robustesse, mais aussi de comparer les robustesses d'une collection de réseaux et de corriger la robustesse d'un réseau dont l'échantillonage serait incomplet. Les méthodes développées sont implémentées dans des packages R et appliquées sur des données issues des sciences sociales et de l'écologie.Title: Statistical learning of collections of networks with applications in ecology and sociology Keywords: Networks, Random graphs, Heterogeneous data, Stochastic block model, Variational method, Unsupervised learning Abstract: This thesis deals with the development of statistical methods for the analysis of collections of interaction networks through three original contributions. Interaction networks are a natural way to represent in graph form the exchanges or relationships existing between a set of nodes representing species or individuals. Considering collections of networks allows to study heterogeneous systems, composed of several kinds of interactions involving different types of nodes. When the different networks of the collection are linked by a hierarchical relationship, we speak of multilevel networks.

  . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.5 Prediction of missing links and NA entries on stream food webs. . . 3.6 Above: Classification and connectivity structures of a collection of 67 predation networks from the Mangal database into 5 groups. The length of the dendrogram is given by the difference in BIC-L to the best model. Below: Contingency table of the classification found by πcolSBM and the different datasets from the Mangal database. . . 3.7 Above: Classification and connectivity structures of a collection of 67 predation networks fron the Mangal database into 3 groups. The length of the dendrogram is given by the difference in BIC-L to the best model. Below: Contingency table of the classification found by δcolSBM and the different datasets from the Mangal database. . .

  fully observed networks computed from partially observed networks. On the left, 12.5% of possible interactions are recoded as NA. and on the right, 25% of species are missing. . . . . . . . . . . . . . . . . . . . . . . 172

	Introduction
	1.1. Motivation

Un réseau est un moyen naturel de représenter un ensemble d'objets interconnectés. Ces objets sont les noeuds du réseau. Ceux-ci sont reliés entre eux par des arêtes signifiant leurs interactions. Selon le domaine d'application, les noeuds et les arêtes du réseau peuvent revêtir diverses significations. Dans cette thèse, je m'intéresse à développer des méthodes pour analyser des réseaux issus des sciences sociales et de l'écologie. Dans un réseau social, les noeuds représentent des acteurs, en général des individus. L'observation des liens existants entre acteurs se fait par exemple suite aux réponses obtenues lors d'entrevues ou de questionnaires. Dans un réseau d'amitié, un acteur est un individu déclarant une relation d'amitié avec d'autres individus. Dans ce cas, la relation d'amitié est généralement réciproque et le réseau est dit non dirigé. Par contre, dans un réseau de relations de conseil, l'interaction signifie la demande de conseil qui est un lien dirigé d'un individu vers un autre. Introduction (fr)

  2

  . . . . . . .

					. . .	. . .
	. . .	. . .	. . .	. . .	. . .	0
	. . .	. . .	. . .

. . . A M -1 I n

  ont proposé le premier modèle classique pour les graphes aléatoires binaires non dirigés, le modèle est paramétré par le nombre de noeuds du graphe et son nombre d'arêtes. Un réseau G = (V, E) à n noeuds et m arêtes est tiré uniformément parmi tous les réseaux possibles ayant le même nombre de noeuds et d'arêtes :

  Dans le SBM, les degrés des noeuds d'un bloc sont distribués suivant une loi de Poisson, alors que de nombreux réseaux réels observés ont une suite des degrés qui suit une loi de puissance ou une loi exponentielle. Pour corriger ce problème, Karrer and Newman (2011) ajoutent un paramètre de degré à chaque noeud. De manière à faciliter les calculs, la loi d'émission est une loi de Poisson, ce qui est raisonnable même pour un réseau binaire tant que le réseau est suffisamment creux. Soit η i , i ∈ V un paramètre spécifique à chaque noeud avec pour des raisons d'identifiabilité i∈q η i = 1, pour tout q ∈ Q, alors conditionnellement aux blocs, les arêtes sont indépendantes et de loi :

.1) Lorsque l'ensemble des covariables sur les noeuds est fini, celles-ci peuvent être transférées au niveau des arêtes. La structure de blocs retrouvée par ce modèle est la structure résiduelle, celle qui n'a pas été expliquée une fois que l'effet des covariables a été pris en compte.

Newman and Clauset (2016) adoptent une approche différente lorsqu'ils traitent des covariables sur les noeuds (métadonnées). Les covariables servent alors à définir des probabilités a priori pour les blocs latents. Lorsque le nombre de covariables est fini, discret et non ordonné, en notant Y i la valeur de la covariable du noeud i, on a : Introduction (fr)

Degree Corrected Stochastic Block Model (DCSBM)

  2 sont représentées par un vecteur {0, 1} M où M est le cardinal du type de relation. En sociologie, cette représentation est utile pour modéliser la réciprocité dans les relations, en considérant un réseau dirigé comme un réseau non-dirigé à deux couches où la loi des arêtes partant des mêmes noeuds est jointe, i.e. on considère alors le couple

  2 plutôt que chaque arête individuellement. Dans ce même esprit, Barbillon et al. (2017) proposent un SBM pour réseaux multiplexes où les arêtes des différentes couches entre deux mêmes noeuds sont liées et dépendent des blocs d'individus :

  Finalement, Vallès-Català et al. (2016) se demandent si un réseau simple n'est pas l'agrégation des différentes couches d'un réseau multiplexe. Pour un réseau à deux couches X = (X 1 , X 2 ), ils considèrent deux modes d'agrégation pour le réseau observé X O . L'agrégation AND où X

  2 et adaptent le SBM à ces deux cas. Peixoto (2015) se sert du réseau agrégé comme covariable pour générer des couches dépendantes d'un réseau multiplexe. Pour les collections de réseaux, Le et al. (2018) supposent l'existence d'un véritable réseau X, dont les réseaux de la collection {X m } m∈M seraient des versions bruitées. Le réseau X suit un SBM et le bruit P ∈ [0, .5] Q×Q et Q ∈ [0, .5] Q×Q respecte la structure par bloc de X de manière que : P

  [START_REF] Miele | Spatially constrained clustering of ecological networks[END_REF] proposent un SBM contraint spatialement en faisant, par une approche de vraisemblance pénalisée, un compromis entre un réseau d'infrastructure connu et les blocs du réseau à analyser.

Autres types de réseaux multicouches

Bar-Hen et al. (2020) proposent une formulation très générale appelée generalized multipartite SBM pour modéliser des réseaux dont la décomposition des noeuds en K groupes fonctionnels est déjà connue. On s'intéresse alors à retrouver des blocs à l'intérieur de ces groupes fonctionnels. Cela revient à étudier une collection de SBM et LBM dont certains partagent les mêmes noeuds et blocs. Ainsi, pour tout k ∈ {1, . . . , K},

  [START_REF] Mariadassou | Convergence of the groups posterior distribution in latent or stochastic block models[END_REF], sur la consistance des estimateurs variationnels[START_REF] Celisse | Consistency of maximumlikelihood and variational estimators in the stochastic block model[END_REF] et leur normalité asymptotique[START_REF] Bickel | Asymptotic normality of maximum likelihood and its variational approximation for stochastic blockmodels[END_REF]. Les résultats sur les estimateurs variationnels ont été étendus aux réseaux ayant des données manquantes (Mariadassou and Tabouy, 2020) et aux réseaux bipartites[START_REF] Brault | Consistency and asymptotic normality of Latent Block Model estimators[END_REF].Quelques travaux dans la littérature ne font pas reposer leur approche variationnelle sur une famille de loi factorisable. D'autres algorithmes se basant sur la propagation des convictions[START_REF] Pearl | Reverend bayes on inference engines: a distributed hierarchical approach[END_REF], Belief Propagation) sont populaires pour les réseaux parcimonieux (Decelle et al., 2011), car l'approximation effectuée dans cet algorithme est exacte pour les réseaux en forme d'arbre. Par ailleurs, les travaux de Yin et al. (2020) ont pour objectif de choisir R parmi une famille de loi plus large. Une version bayésienne de l'approche variationnelle est développée par Latouche et al. (2012).Pour plus de détails sur le spectral clustering, je renvoie vers Von[START_REF] Luxburg | A tutorial on spectral clustering[END_REF].Bien que les premiers travaux sur le SBM supposent le nombre de groupes fixé (Snijders and Nowicki, 1997), de nombreuses méthodes ont été développées depuis pour estimer le nombre de blocs dans le SBM. La revue de Lee and Wilkinson (2019) procure d'avantage de détails. Certains travaux se basent sur des méthodes de validation croisée, en leave-one-out (Kawamoto and Kabashima, 2017) ou par bloc de la matrice d'adjacence[START_REF] Chen | Network Cross-Validation for Determining the Number of Communities in Network Data[END_REF]. L'avantage de ces méthodes est qu'elles sont facilement généralisables à des modèles plus complexes et permettent, en plus de choisir le nombre de blocs, de comparer différents modèles entre eux par exemple

	Initialisation 1.2.6. Sélection de modèle

Pour proposer une partition des noeuds, on utilise le maximum a posteriori (MAP) après convergence de l'algorithme VEM en posant : ẐMAP i (de l'algorithme VEM La borne variationnelle n'est pas concave et l'algorithme VEM peut se coincer dans des maximaux locaux de la borne variationnelle. Ainsi, l'algorithme est très sensible à l'initialisation. Des stratégies d'initialisation communément utilisées incluent, d'essayer un grand nombre d'initialisation aléatoire, d'utiliser le clustering obtenu à partir d'un algorithme moins coûteux tel que le clustering spectral ou bien d'initialiser à partir de modèle voisin (des modèles tels que le nombre de blocs appartient à {Q -1, Q + 1}) (Daudin et al., 2008; Leger et al., 2020). Lorsque un modèle voisin a été inféré, la classification des noeuds qu'il procure peut servir de bon point d'initialisation locale pour l'algorithme VEM. Pour obtenir cette initialisation, si le nombre de blocs initiaux est plus grand que Q, on fusionne alors 2 blocs, tandis que si ce nombre est plus petit, on sépare un bloc en deux (le bloc q par exemple) en réalisant un clustering des lignes de la matrice (A ij ) i∈q,j∈V . Introduction (fr) un SBM et un DCSBM. Toutefois, Vallès-Català et al. (

2017

) mettent en garde contre les risques de surapprentissage, le modèle donnant les meilleurs prédictions n'étant pas forcément le plus parcimonieux au sens de la minimum description length (MDL). Ce critère est souvent utilisé dans les formulations bayésiennes du SBM

[START_REF] Peixoto | Hierarchical block structures and high-resolution model selection in large networks[END_REF]

.

Ce critère est comparable, sous certaines hypothèses à l'integrated classification likelihood

[START_REF] Biernacki | Assessing a mixture model for clustering with the integrated completed likelihood[END_REF] Daudin et al., 2008, ICL)

, critère que j'adapterai dans mes travaux. Je donne ici l'idée principale, des développements plus détaillés ayant lieu dans les chapitres 2 et 3. Développé pour les modèles de mélange, l'ICL favorise des blocs bien séparés. Il s'obtient en prenant le log de la vraisemblance intégrée sur les paramètres du modèle des données complètes : log L(X, Z|Q) = log α L α (X|Z, Q)p(α|Q)dα + log π L π (Z|Q)p(π|Q)dπ,

(1.5)

  La pénalité est facilement interprétable : le premier terme dépend du nombre de degré de liberté du paramètre de mélange π et du nombre de noeuds, tandis que le second dépend du nombre de paramètres de connexion et du nombre de dyades.Dans le cadre du SBM, pour de nombreuses lois d'émission ayant des lois a priori conjuguées, l'approximation asymptotique n'est pas nécessaire.[START_REF] Latouche | Variational bayesian inference and complexity control for stochastic block models[END_REF] utilisent une version non asymptotique comme critère de sélection, le couplant à une approximation de la vraisemblance observée par méthode bayésienne variationnelle. Ils argumentent que l'objectif est différent de celui de l'ICL, car leur critère (ILvb) se focalise sur l'estimation de la densité et non sur celle de la classification. On dispose d'une expression analytique pour l'équation (1.5), on parle alors d'ICL exact et ce critère devient la fonction objectif à optimiser[START_REF] Côme | Model selection and clustering in stochastic block models based on the exact integrated complete data likelihood[END_REF]. Cela permet d'optimiser le nombre de blocs en même temps que le clustering, sans passer par un algorithme variationnel pour chaque taille de modèle.

) . Hayashi et al. (2015) adaptent et simplifient le Factorized Information Criterion(FIC) aux modèles de mélange, pour le SBM ce critère est appelé BICEM ou corrected ICL (cICL) : cICL = E Z|X [ θ(X, Z)] -pen(Q) + H(p(Z|X)), cela revient à rajouter un terme d'entropie à l'ICL évalué avec la loi a posteriori des variables latentes et donc, comme ILvb, à approcher la vraisemblance des données observées plutôt que la vraisemblance classifiante. Hayashi et al. (2016) comparent cette approche avec d'autres critères, dont une implémentation directe du FIC dans des modèles bayésiens pour des graphes parcimonieux, qui permet d'intégrer la sélection de modèle à l'inférence. D'autres approches par vraisemblance pénalisée ont été développées. Yan (2016) propose un critère de sélection bayésien permettant de comparer différents modèles (model selection) ayant un nombre de groupes différent (order selection) et l'applique au SBM et au DCSBM. Wang and Bickel (2017) regardent si des blocs peuvent être séparés en analysant le rapport de vraisemblance et en dérivent un critère de vraisemblance pénalisée consistant, de la forme

  Bien que les résultats empiriques montrent que l'ICL donne de très bons résultats pour les réseaux denses, signalons que dans les cas où le nombre de blocs trouvé n'est pas le bon, l'ICL a tendance à sous-estimer le nombre de blocs(Hu et al., 2020; Hayashi et al., 2016; Latouche et al., 2011; Mariadassou et al., 2010). En passant en revue les différents critères de sélection de modèle ci-dessus, nous remarquons que certains se concentrent sur le clustering des données, i.e. retrouver le bon nombre de clusters, tandis que d'autres essaient de retrouver la bonne dimension du modèle, i.e. retrouver le bon nombre de paramètres. Dans le cadre du SBM ces deux approches sont liées et nous illustrons cela en comparant la version asymptotique de l'ICL (version McLachlan and Peel, 2000) au BIC

	Lien entre ICL et BIC

[START_REF] Saldaña | How Many Communities Are There?[END_REF]

proposent un composite-likelihood BIC en considérant les Z fixes et inconnus (pas une variable latente) et arrivent à une pénalité en Q(Q+1) Introduction (fr)

Table 1 .

 1 1 -Quelques SBM pour réseaux multicouches et collection de réseaux

1.2.7. Comparaison de clustering

  La comparaison de clustering a de nombreuses applications dans le cadre de l'analyse de réseaux. Cela permet entre autre de :

	1. Juger dans le cadre de simulations de la performance des algorithmes et des
	méthodes d'inférence,
	2. Juger de la stabilité des clusterings obtenus, en relançant les algorithmes à
	partir de données bruitées (cf. section 1.2.8),
	3. Comparer les clusterings obtenus via différentes méthodes,
	4. Quantifier la similarité entre différentes couches d'un réseau multiplexe ou
	temporel, ou différents réseaux d'une collection impliquant les mêmes noeuds.
	Certains auteurs
	s'intéressent également à comparer les clusterings obtenus à ceux d'un ground truth
	(une vérité de terrain qui correspond à une covariable qualitative sur les noeuds) (Hric
	et al., 2014). Je n'adopterai pas cette solution car elle me parait inadaptée et mal
	posée (Peel et al., 2017; Olhede and Wolfe, 2013). En particulier, Peel et al. (2017)
	montrent que la partition des noeuds pouvant générer le réseau n'est pas unique
	et prouvent un no free lunch theorem avec l'adjusted mutual information (AMI)
	comme indice de comparaison de clustering. Par ailleurs, bien que le SBM permet
	de retrouver des formes de structures universelles (Young et al., 2018), quelques
	travaux récents restreignent l'espace des paramètres de manière à retrouver des
	structures facilement interprétables : communautaire (Zhang and Peixoto, 2020) ou
	coeur-périphérie (Zhang et al., 2015; Gallagher et al., 2021).
	Je présente deux indices particulièrement utilisés dans le cadre des réseaux. L'un
	est basé sur la théorie de l'information, le NMI (Danon et al., 2005, Normalized
	Mutual Information) et l'autre, l'ARI (Hubert and Arabie, 1985, Adjusted Rand
	Index), sur le principe du comptage de paires. Pour une discussion sur les avantages
	de différents indices de comparaison de partitions, je renvoie à l'article de Fortunato
	and Hric (2016).

À propos du premier point, pour juger de l'efficacité de la modélisation et de son implémentation à retrouver les vrais clusters, il existe des benchmarks à partir de réseaux simulés

[START_REF] Lancichinetti | Community detection algorithms: A comparative analysis[END_REF]

. Toutefois le SBM est un modèle génératif et il est aisé de simuler à partir du modèle.

  NMI vaut 1 si les partitions sont identiques et 0 si elles sont indépendantes.

	Je signale que l'AMI utilisée ci-dessus par Peel et al. (2017) est une version ajustée
	du NMI qui prend en compte la géométrie de l'espace des clusterings. En notant
	I(C, D) l'information mutuelle au numérateur de l'équation (1.6), elle est donnée
	par :
	AMI(C, D) =	I(C, D) -E[I(C, D)]	.
		H(C)H(D) -E[I(C, D)]
	ARI Pour l'ARI, on regarde si des paires de noeuds sont classées dans le même
	bloc ou non dans les 2 clusterings. Cela revient à regarder pour chaque dyade, si elle
	est intra-bloc ou inter-bloc. Introduisons les valeurs suivantes pour chaque couple de
	clusterings :

1.2.8. Données manquantes et bruitées

	Un réseau observé peut comporter des données manquantes, sur les noeuds, les
	covariables ou les dyades. Dans ce qui suit je me concentrerai sur les dyades du
	réseau. La problématique est différente sur les réseaux d'interactions en écologie et
	en sciences sociales.
	Concernant les réseaux d'interactions écologiques, il est difficile de faire la différence
	entre une arête non-existante et une arête non-observée. Notre capacité à observer des
	interactions dépend du temps d'observation, celui-ci étant fini, les réseaux écologiques
	observés sont connus pour être incomplets (Blüthgen et al., 2008). Si je prends le cas
	d'un réseau binaire, certains 0 sont des "faux" 0 et on peut s'intéresser à prédire les
	liens manquants du réseau (Clauset et al., 2008). Réciproquement certaines erreurs
	ont pu avoir lieu lors de la collecte des données : une espèce a été confondue avec
	une autre, une erreur s'est produite lors de la numérisation des données, etc. . . Ainsi,
	il est possible d'observer des arêtes fallacieuses que l'on peut également essayer de
	distinguer des véritables arêtes (Guimerà and Sales-Pardo, 2009).
	Pour les réseaux sociaux, bien que l'on puisse également observer des liens fallacieux
	ou manquants, des dyades peuvent également être non observées. Cela peut se
	produire lorsqu'un formulaire est rempli de manière incomplète ou bien que via la
	méthode d'échantillonnage choisie pour observer le réseau, certains individus présents
	dans le réseau n'aient pas pu être interviewés, n'aient pas répondu à un questionnaire
	(Žnidaršič et al., 2012) ou plus généralement que certaines informations n'aient pas pu
	être récoltées. Dans ce cas là, nous savons où se trouvent les informations manquantes.
	On peut alors s'intéresser à inférer un modèle à partir du réseau partiellement observé
	et/ou à prédire les valeurs des dyades manquantes.
	De nombreuses méthodes ont été développées pour prédire les liens ou les dyades
	manquants (Martínez et al., 2016, pour une revue) et le SBM et sa version degré
	corrigé ont montré de bonnes performances sur des réseaux réels (Ghasemian et al.,
	2020a,b). De plus des résultats d'identifiabilité et des résultats asymptotiques sur les
	estimateurs (du maximum de vraisemblance et variationnels) existent pour différentes
	stratégies d'échantillonage (Tabouy et al., 2019; Mariadassou and Tabouy, 2020).
	Soit D = D O ∪ D U , la division des dyades en dyades observées (D O ) et dyades non-
	observées (D U ). L'objectif est de retrouver la distribution de D U |D O . Représentons
	le réseau sous forme matricielle où X ij = NA pour tout (i, j) ∈ D U . Alors dans le
	cadre d'un SBM pour un réseau simple binaire :

1.3.1. Un modèle à blocs stochastiques pour les réseaux multiniveaux

  1} n I ×n I et X O ∈ {0, 1} n O ×n O , tandis que les affiliations le sont par une matrice A de taille n I × n O tel que : O organisations sont réparties dans Q O blocs et que les n I individus sont répartis dans Q I blocs. Soient Z O = (Z O

	Dans le chapitre 2, un réseau multiniveau est défini comme la collection d'un
	réseau (niveau) inter-individuel, un réseau (niveau) inter-organisationnel et un
	réseau d'affiliation des individus aux organisations. Nous faisons l'hypothèse qu'un
	individu est affilié à une unique organisation. Dans le cadre d'un réseau multiniveau
	non dirigé avec n I individus et n O organisations, les niveaux inter-individuels et
	inter-organisationnels sont représentés par les matrices d'adjacences binaires X I ∈
	{0, A ij =	  	1 si l'individu i est affilié à l'organisation j, 0 sinon	.
	A est tel que ∀i = 1, . . . , n I , n O j=1 A ij = 1 car chaque individu est affilié à une et
	une seule organisation.
	Nous proposons une modélisation jointe des réseaux inter-individuel et inter-
	organisationnel à partir d'une extension du SBM appelé MLVSBM. Plus précisément,
	supposons que les n 1 , . . . , Z O n O ) et Z I = (Z I 1 , . . . , Z I n I ) tels que Z O j = l si l'organisation j appartient au cluster l (l ∈ {1, . . . , Q O }) et
	Z I i = k si l'individu i appartient au cluster k (k ∈ {1, . . . , Q I }). Sachant les blocs,
	nous supposons que les interactions entre organisations et entre individus sont
	indépendantes et distribuées comme suit :

  Représentation d'un réseau multiniveau avec le niveau interorganisationnel en haut et le niveau inter-individuel en bas.

	Résultats théoriques Nous montrons l'identifiabilité du modèle et dérivons des
	conditions sur l'indépendance structurelle entre les niveaux en terme d'égalité entre
	paramètres. Cette proposition est fondamentale car elle permet de réécrire le modèle
	pour un réseau multiniveau comme le produit de deux SBMs indépendants, un pour
	chaque réseau, et de vérifier si l'hypothèse de dépendance multiniveau est adapté à
	ce réseau.
	Proposition 1.1. Dans le MLVSBM, les deux propositions sont équivalentes :
	1. Z I est indépendant de Z O
	2. γ kl = γ kl ∀l, l ∈ {1, . . . , Q O }, ∀k ∈ {1, . . . , Q I }
	et implique :
	3. X I et X O sont indépendants.
	L'inférence du MLVSBM s'effectue via des méthodes variationnelles (cf. section 1.2.5)
	à travers un algorithme VEM adapté à ce modèle, tandis que nous développons
	un critère ICL pour sélectionner le nombre de blocs. La proposition 1.1 permet
	également d'utiliser l'ICL pour juger qu'il y a indépendance des deux niveaux si :
	max

1.3.3. Estimation de la robustesse de réseaux d'interactions écologiques bipartites

	Dans le chapitre 4, nous nous intéressons à relier la robustesse, un indice communé-
	ment utilisé en écologie pour quantifier la résilience d'un écosystème à la disparition
	d'espèces, à la structure du réseau représentant cet écosystème. Nous nous focalisons
	sur les réseaux d'interactions bipartites, où nous regardons l'influence des extinc-
	tions des espèces en ligne (extinctions primaires) sur les extinctions d'espèces en
	colonnes (extinctions secondaires). Pour cela, on se donne une loi sur les séquences
	d'extinctions primaires S, la statistique de robustesse pour un réseau A de taille
	n r × n c sous cette loi d'extinction est donnée par

un niveau représentant les interactions entre individus et l'autre les interactions entre organisations. Les niveaux sont liés par une relation d'affiliation, chaque individu appartenant à une organisation unique. Un nouveau modèle à blocs stochastiques est proposé comme cadre probabiliste unifié, adapté aux réseaux

  multiniveaux. Ce modèle contient des blocs latents qui représentent de l'hétérogénéité dans les profils de connexion au sein de chaque niveau et qui introduisent des dépendances entre les niveaux. Les profils de connexion recherchés ne sont pas spécifiés a priori, ce qui rend cette approche flexible. Des méthodes variationnelles sont utilisées pour l'inférence du modèle et un critère de vraisemblance classifiante intégrée est développé pour choisir le nombre de blocs et aussi pour décider si les deux niveaux sont dépendants ou non. Une étude de simulation complète montre l'avantage de considérer cette approche, illustre la robustesse du clustering et met en évidence la fiabilité du critère utilisé pour la sélection du modèle. Cette approche est appliquée sur un ensemble de données sociologiques collectées lors de salons professionnels d'échange de programmes de télévision, le niveau inter-organisationnel étant le réseau économique entre les entreprises et le niveau inter-individuel étant le réseau informel entre leurs représentants. Elle apporte une représentation synthétique des deux réseaux en démêlant leur structure entrelacée et confirme la coopétition en jeu.

	A Stochastic Block Model for the Analysis of Multilevel Networks A Stochastic Block Model for the Analysis of Multilevel Networks 2.1. Introduction 43
	• Le package MLVSBM (Chabert-Liddell, 2021a), disponible sur le CRAN (ht tps://CRAN.R-project.org/package=MLVSBM), implémente les méthodes décrites au chapitre 2. Il permet la simulation et la prédiction d'arêtes de réseaux multiniveaux, ainsi que l'estimation des paramètres, des blocs latents et la sélection de modèle pour un MLVSBM. Le package repose sur de la programmation orientée objet à travers l'utilisation de classes R6. Une vignette illustrant son utilisation ainsi qu'une autre illustrant l'intêret de la modélisation multiniveau via une étude de simulation sont disponibles en appendice du chapitre 2. Ces vignettes sont reproduites à partir de celles disponibles sur le site dédié au package, qui propose une documentation complète : https: //Chabert-Liddell.github.io/MLVSBM. • Le package colSBM qui a servi à faire les simulations et les applications du chapitre 3 est disponible sur github (https://Chabert-Liddell.github.io/colS BM). Il repose également sur de la programmation orientée objet à travers l'utilisation de classes R6. Son utilisation est illustrée à travers une application 2.E.1 Description of the generative model . . . . . . . . . . . . . . 79 2.E.2 Variational inference . . . . . . . . . . . . . . . . . . . . . . 81 2.F MLVSBM package Tutorial . . . . . . . . . . . . . . . . . . . . . . 83 2.F.1 Generic functions . . . . . . . . . . . . . . . . . . . . . . . . 84 2.F.2 Other useful output . . . . . . . . . . . . . . . . . . . . . . . 85 2.G Hard to Infer Levels: Benefits of the Multilevel Modeling . . . . . . 86 2.G.1 Simulation Scenario . . . . . . . . . . . . . . . . . . . . . . . 87 2.G.2 Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 88 Motivation Le travail qui suit est motivé par l'analyse des réseaux multiniveaux. L'idée émerge des travaux de Barbillon et al. (2017) qui traitent un réseau multiniveau comme un réseau multiplexe en considérant les interactions entre organisations comme des interactions entre individus via leurs organisations. Une approche qui n'est raisonnable que si le nombre d'individu par organisation est proche de 1. Pour pallier ce problème, il est nécessaire de développer un modèle qui prenne en compte la structure particulière de dépendance entre les niveaux des réseaux multiniveaux habituels. Ces travaux ont fait l'objet d'une collaboration avec le sociologue Emmanuel Lazega. Résumé Un réseau multiniveau est défini comme la jonction de deux réseaux fait l'objet d'un article (Chabert-Liddell et al., 2021) publié dans le journal Compu-tational Statistics & Data Analysis. Un package R nommé MLVSBM, disponible sur le CRAN (Chabert-Liddell, 2021a), dont la documentation est disponible à l'adresse thodes développées ci-dessous. Ce package fait l'objet des annexes 2.F montrant un tutoriel et un exemple d'application illustrant l'intérêt de l'approche multiniveau. Notations for this chapter n I The number of individuals X I The inter-individual level, an n I × n I adjacency matrix, X O The inter-organizational level, an n O × n O adjacency matrix A The affiliation relationship, a n I × n O matrix X The observed variables {X I , X O } Z I The block membership of individuals Z O The block membership of organizations Z The latent variables {Z I , Z O } Q I The number of individual blocks Q O The number of organizational blocks α I The inter-individual connectivity parameters, a Q I × Q I matrix α O The inter-organizational connectivity parameters, a Q O × Q O matrix γ The mixture parameters of individuals, a Q I × Q O matrix π O The mixture parameters of organizations θ The set of parameters ( π O , γ , α O , α I ) τ I The variational parameters for individual block memberships τ I The variational parameters for organizational block memberships Abstract A multilevel network is defined as the junction of two interaction net-works, one level representing the interactions between individuals and the other the interactions between organizations. The levels are linked by an affiliation relationship, each individual belonging to a unique organization. A new Stochastic Block Model d'interaction, Diffusion Le contenu de ce chapitre ainsi que les quatre premières annexes ont suivante https://Chabert-Liddell.github.io/MLVSBM/, permet d'appliquer les mé-n O The number of organizations is proposed as a unified probabilistic framework tailored for multilevel networks.
	à des données de réseaux de conseils en appendice du chapitre 3.
	• Le package robber (Chabert-Liddell, 2021b), disponible sur le CRAN (https:
	//CRAN.R-project.org/package=robber), propose différentes méthodes pour
	calculer la robustesse de réseaux écologiques bipartites. Il implémente entre
	autres les méthodes empiriques et par biSBM pour calculer la robustesse
	décrite au chapitre 4. Une démonstration du package à travers l'analyse et la
	comparaison de la robustesse d'une collection de réseaux décrivant différents
	types d'interactions (pollinisation, dispersion de graines, parasitisme) est
	disponible en appendice du chapitre 4. Une documentation détaillée et une
	vignette permettant de reproduire les analyses topologiques de l'article sont
	disponibles sur le site internet dédié https://Chabert-Liddell.github.io/robber

  A Stochastic Block Model for the Analysis of Multilevel Networks

	the organizations. Besides, we assume that the individuals belong to a unique
	organization. Such a dataset is studied by Lazega et al. (2008), some researchers in
	cancerology being the individuals and their laboratories the organizations. Brailly
	et al. (2016) deal with another dataset concerned with the economic network of
	audiovisual firms and the informal network of their sales representatives during a
	trade fair. This latter dataset will be analyzed in this paper.
	In the last years, the Stochastic Block Model (SBM developed by Holland et al., 1983;
	Snijders and Nowicki, 1997) has become a popular tool to model the heterogeneity
	of connection in a network, assuming that the actors at stake are divided into blocks
	(clusters) and that the members of a same block share a similar profile of connectivity.
	Compared to other graph clustering methods such as modularity maximization,
	hierarchical clustering or spectral clustering (see Kolaczyk, 2009, and references
	therein), the SBM is a generative model, it shares with the generalized blockmodeling
	(Doreian et al., 2005

  .1 the average computation time using the R package MLVSBM on two cores of a desktop computer with 32GB of RAM and a Intel® Xeon(R) CPU E5-1650 v4 @ 3.60GHz × 12 processor running on Ubuntu 18.04.5 LTS for the inference of simulated networks including model selection for different network sizes and different numbers of blocks. A Stochastic Block Model for the Analysis of Multilevel Networks

	Network Size	Running time (mean ± sd) in seconds

Table 2 .

 2 1 -Average running time for the inference of the MLVSBM for different network sizes and different numbers of blocks.

	8

Table 2 .

 2

	2.5. Application to the multilevel network issued from a television programs trade
	fair							65
	Organizations			Covariates
	Block Size Producer Distributor Media	Independent	Broadcaster
					group	buyer
	1	61	14	16	9		14	8
	2	20	1	0	2		7	10
	3	28	3	19	5		1	0
		Individuals	Covariates	Affiliation
		Block Size Buyer Seller 1 2 3
		1	18	18	0	6 12 0
		2	22	16	6	13 8 1
		3	25	2	23	7 0 18
		4	63	15	48	42 8 13

2 -Contingency table of covariates and clustering for the organizations (top)

and the individuals (bottom)

  combining this result with Equations (2.B.20) and (2.B.19) leads to:

  O ), we have to adapt the calculus. Let us set independent Dirichlet prior distributions of order Q I D(1/2, . . . , 1/2) on the columns γ •l . We are able to derive an exact expression of log γ

.D.26) For quantity (2.D.23) depending on γ and Z I given (Q I , Q

  CollectionJoint inference of a collection of networks 95 différents SBM, qui partagent par des paramètres communs la même structure de connectivité, éventuellement à proportions des blocs et/ou un facteur de densité près. Les paramètres du modèle sont estimés et les blocs latents sont récupérés en utilisant un algorithme EM variationnel. L'existence d'un bon compromis entre les structures méso-échelle de ces réseaux n'est pas garantie. Nous utilisons un critère ad-hoc, basé sur la vraisemblance classifiante intégrée (ICL) pour sélectionner le nombre de blocs et évaluer l'adéquation du consensus trouvé entre les structures des différents réseaux. Ce critère peut également être utilisé pour regrouper les réseaux sur la base de leurs structures de connectivité. Il fournit ainsi une partition de la collection en sous-ensembles de réseaux structurellement homogènes.Une application à une collection de trois réseaux trophiques de cours d'eau révèle l'homogénéité de leurs structures et fournit une structure plus détaillée des plus petits réseaux. Enfin, nous montrons comment 67 réseaux trophiques peuvent être regroupés et ainsi décrits par un petit nombre de structures de connectivité.

Diffusion Le contenu de ce chapitre et des 3 premières appendices sera soumis très prochainement dans une revue de statistiques. Une application détaillée à une collection de 4 réseaux de conseils entre juges, avocats, prêtres ou chercheurs est donnée en appendice 3.D. Elle fournie quelques idées d'extensions dans les applications potentielles des méthodes colSBM . Joint inference of a collection of networks

Notation for this chapter

  al., 2014). Furthermore, the networks are assumed to have interactions of the same type (directed or not) and with the same valuation (binary, discrete or continuous). A set of such networks forms what we call in this paper a collection of networks, although some authors may use this terminology in a different meaning. When observing such a collection, we aim to determine if the respective structures of the networks are similar.A classical tool to infer the mesoscale structure of a single network is the Stochastic Block Model[START_REF] Holland | Stochastic blockmodels: First steps[END_REF] Snijders and Nowicki, 1997, SBM). In this model, a latent variable is associated with each node giving its group/block membership. Nodes belonging to the same block share the same connectivity pattern. The SBM has easily interpretable parameters and its framework allows multiple extensions such as modeling the interactions with various distributions[START_REF] Mariadassou | Uncovering latent structure in valued graphs: a variational approach[END_REF].

Inferring independently the structures for each network and comparing them may be misleading. Indeed, a given network may have several possible clusterings of the nodes

[START_REF] Peel | The ground truth about metadata and community detection in networks[END_REF]

with similar probabilities

[START_REF] Peixoto | Hierarchical block structures and high-resolution model selection in large networks[END_REF]

. Furthermore, the observation of a network may be noisy (Guimerà and Sales-Pardo, 2009), especially for ecological networks, the sampling of which is known to be incomplete (Rivera-Hutinel et al., 2012).

  colSBM s with VEM starting from merged Ẑm sep-SBM (Q) (many initializations as a result of permutations within each Ẑm sep-SBM (Q)) -Keep the b fitted models with the best BIC-L for each Q

while BIC-L is increasing do -Forward loop for Q = Q min + 1, . . . , Q max do -Fit colSBM with Q blocks from initializations obtained by splitting a block in models with Q -1 blocks if π-δπcolSBM s then -Fit colSBM with S qm = 1 πm q >t for different value of threshold t -Backward loop for

Table 3 . 2 -

 32 ) . Accuracy of the inference for varying α. All the quality indicators are averaged over the 30 simulated datasets. . All these quality indicators are averaged among the 30 simulated datasets. The results are provided in Table 3.2. Each line corresponds to the 30 datasets simulated with a given value of α . The first columns concatenate the results of the model comparison task. The following set of columns is about the selection of Q and the estimation of S. The last columns supply the RMSE on α and the ARI.

	Collection

Table 3 . 3 -

 33 1. Joint inference of a collection of networks Model selection for varying mixture parameters. The number of blocks Q is given for the π-colSBM . The similarity of the block support to the true one Rec( Ŝ, S) is given for π-colSBM with Q = 4.

			Model comparison		Estimation of Q and S
					under π-colSBM
	π	iid-colSBM π-colSBM sep-SBM 1 Q=4	Rec( Ŝ, S)
	0	1	0	0	1	1
	.04	1	0	0	1	1
	.08	.9	.1	0	1	1
	.12	.5	.5	0	1	1
	.16	.37	.63	0	1	.97
	.2	.03	.97	0	1	1

Table 3 .

 3 6 -Indices for the structures obtained by δπ-colSBM for the lawyers and the priests networks.

		Lawyers Lawyers (colSBM) Priests Priests (colSBM)
	Modularity	0.127	0.121	0.216	0.224
	Nestedness	0.747	0.760	0.725	0.693
	Reciprocity	0.618	0.596	0.788	0.851

Table 3 .

 3 .7. 7 -Indices for the structures obtained by π-colSBM for the lawyers and the researchers networks.

		Lawyers Researchers Lawyers (colSBM) Researchers (colSBM)
	Modularity	0.222	0.257	0.233	0.245
	Nestedness	0.681	0.673	0.694	0.670
	Reciprocity	0.796	0.828	0.815	0.848

Table 3 .

 3 8.

		Priests Researchers Priests (colSBM) Researchers (colSBM)
	Modularity	0.187	0.249	0.225	0.225
	Nestedness	0.710	0.683	0.693	0.693
	Reciprocity	0.789	0.845	0.824	0.824

Table 3 .

 3 8 -Indices for the structures obtained by iid-colSBM for the researchers and the priests networks.

	0.00
	0.25
					alpha
					0.4
	0.50				0.3
					0.2
					0.1
	0.75
	1.00 0.00	0.25	0.50	0.75	1.00

Table 3 . 9 .

 39 Joint inference of a collection of networks

	Model	Jud_Law_Pri Jud_Law_Res Jud_Pri_Res Law_Pri_Res Jud_Law_Pri_Res
	sep-SBM	-7964	-9329	-9158	-7177	-11210
	iid-colSBM	-8032	-9397	-9187	-7128	-11254
	π-colSBM	-7988	-9377	-9176	-7130	-11213
	δ-colSBM	-8034	-9406	-9169	-7138	-11256
	δπ-colSBM	-7983	-9377	-9168	-7137	-11231

Table 3 .

 3 [START_REF] Bianconi | Multilayer Networks: Structure and Function[END_REF] -Indices of the structures obtained by π-colSBM for the lawyers, priests and researchers advice networks.

			Priests Researchers
	Modularity	0.228	0.186	0.261
	Nestedness	0.679	0.705	0.667
	Reciprocity	0.797	0.786	0.838
	Lawyers (colSBM) Priests (colSBM) Researchers (colSBM)
	Modularity	0.212	0.211	0.254
	Nestedness	0.714	0.703	0.656
	Reciprocity	0.805	0.855	0.860

Table 3 .

 3 [START_REF] Bickel | The method of moments and degree distributions for network models[END_REF] -Indices of the structure obtained by π-colSBM for the judges, lawyers, priests and researchers advice networks.

		Judges Lawyers Priests Researchers
	Modularity	0.010	0.178	0.133	0.231
	Nestedness	0.882	0.695	0.773	0.715
	Reciprocity	0.392	0.672	0.725	0.865

  4.B.2 Analyzing the link between richness, connectance and interaction type for empirical robustness . . . . . . . . . . . . . . . 180 4.B.3 Normalized robustness . . . . . . . . . . . . . . . . . . . . . 183 4.B.4 Examining if networks are more robust to plant or animal extinctions . . . . . . . . . . . . . . . . . . . . . . . . . . . . 184 Motivation L'idée de ce travail est née des discussions avec les écologues Sonia Kéfi et François Massol dans le cadre de l'ANR Econet. L'objectif est de mieux comprendre le lien entre la structure du réseau et la robustesse et de proposer une méthode permettant de comprendre comment la robustesse des réseaux écologiques varie selon le type d'interaction concerné. Résumé La robustesse d'un réseau écologique quantifie la résilience de l'écosystème qu'il représente à la perte d'espèces. Elle correspond à la proportion d'espèces qui sont déconnectées du reste du réseau lorsque des extinctions se produisent de manière séquentielle. Classiquement, la robustesse est calculée pour un réseau donné, à partir de la simulation d'un grand nombre de séquences d'extinction. Le lien entre la structure du réseau et la robustesse reste une question ouverte. La définition d'un modèle probabiliste conjointement sur le réseau et les séquences d'extinction permet d'analyser cette relation. Les modèles de blocs stochastiques bipartites ont prouvé leur capacité à modéliser les réseaux bipartites, par exemple dans les réseaux plantespollinisateurs : les espèces sont divisées en blocs et les probabilités d'interaction sont déterminées par les blocs d'appartenance. Des expressions analytiques de l'espérance et de la variance de la robustesse sont obtenues sous ce modèle, pour différentes distributions de séquences d'extinction primaire. L'impact de la structure du réseau sur la robustesse est analysé à travers un ensemble de propriétés et d'illustrations numériques. L'analyse d'une collection de réseaux écologiques bipartites nous permet de comparer l'approche empirique à notre approche probabiliste, et illustre la pertinence de cette dernière lorsqu'il s'agit de calculer la robustesse d'un réseau partiellement observé ou incomplètement échantillonné.

  has advocated for the use of groups in ecological networks, SBMs (sometimes referred to as group models) have gained in popularity. Some variants adapted to multilayer ecological networks have been proposed for: multiplex networks[START_REF] Kéfi | How structured is the entangled bank? the surprisingly simple organization of multiplex ecological networks leads to increased persistence and resilience[END_REF], multipartite networks (Bar-Hen et al., 2020) or temporal networks[START_REF] Matias | Statistical clustering of temporal networks through a dynamic stochastic block model[END_REF]. Besides, they have been used to answer specific ecological questions. To name a few, Michalska-Smith et al. (2018) explore the structural role of parasite species in food webs, while Miele et al.

Block Model and re- lated sequential extinctions 4.3.1. Probabilistic model on bipartite ecological networks Bipartite stochastic block models

  The bipartite SBM, a.k.a. the Latent Block Model

  m ) qq , through the computation of Equation (4.15). The second term in Equation (4.16) is provided in Proposition 4.3. Thus we are able to compute the remaining terms to understand the various sources of variability (due to S or A).

Table 4 .

 4 1 -Analysis of Variance Table for Empirical Robustness

	Extinction	Res.Df	RSS	adj.R 2	F	Pr(>F)
	Uniform	76	0.0708	0.892	NA	NA
	Uniform	64	0.03208	0.938 6.438	2.413e-07
	Increasing	76	0.1603	0.303	NA	NA
	Increasing	64	0.1052	0.421 2.795	0.003991
	Decreasing	76	0.3128	0.778	NA	NA
	Decreasing	64	0.2583	0.768 1.124	0.3571

  Cette thèse est divisée en trois travaux principaux. Dans un premier chapitre, consacré aux réseaux multiniveaux, nous avons développé un SBM adapté à ce type de données. Dans un autre travail, nous avons proposé des extensions du SBM adaptées à la modélisation conjointe d'une collection de réseau. Un des objectifs était de trouver une structure à l'échelle mésoscopique commune aux réseaux de la collection, et de partitionner la collection en groupes de réseaux ayant la même structure méso-échelle. Enfin, dans le dernier chapitre nous nous sommes intéressés à la relation entre la robustesse d'un réseau bipartite et sa structure. En particulier, dans le cas où le réseau est supposé être la réalisation d'un SBM bipartite, nous avons réussi à exprimer la robustesse du réseau en une fonction des paramètres de ce SBM.Dans ce qui suit, je propose dans un premier temps, quelques pistes dans la continuation des travaux sur la modélisation jointe de réseaux. Puis, je me concentrerai sur des extensions liées à la robustesse et sur l'intêret d'utiliser la modélisation jointe lorsque nous étudions une collection de plusieurs réseaux.Motivés par des applications en sociologie et en écologie, les travaux sur les réseaux multiniveaux et les collections de réseaux ont montré l'intérêt de prendre en compte les réseaux collectivement plutôt qu'individuellement. En particulier, pour comprendre si la modélisation conjointe était pertinente nous avons raisonné en termes respectivement de dépendance entre structures de connections des différents niveaux pour les réseaux multiniveaux et de similarité entre les réseaux pour les collections de réseaux. Ces dépendances et similarités peuvent être expliquées par d'autres facteurs que la structure des interactions. Ainsi, intégrer des covariables (Mariadassou et al., 2010) permettrait de mieux séparer ce qui relève proprement de la structure du réseau, de ce qui peut être expliqué par des caractéristiques extérieures.

										Chapter 5
					Conclusions et perspectives
						0.8			0.50	0.40
	uniform.T	0.7 0.8 0.9		decreasing.T	0.4 0.6		uniform.norm.T	0.40 0.45	decreasing.norm.T	0.20 0.25 0.30 0.35
			0.6			0.2			0.35
										0.35	0.40	0.45	0.20 0.25 0.30 0.35 0.40 0.45
			0.6	0.7 uniform 0.8	0.9	0.2	0.4 decreasing 0.6	0.8		0.7	uniform.norm	decreasing.norm
	increasing.T	0.85 0.90 0.95 1.00				type M_PL M_SD	increasing.norm.T	0.5 0.6	type M_PL M_SD
			0.80 0.85 0.90 0.95 1.00					0.4	0.5	0.6
				increasing						increasing.norm
	Conclusion									Conclusion

Un réseau d'interactions écologiques représente les relations entre espèces dans un écosystème. Ces données peuvent-être le fruit d'observations de terrain ou de connaissances préexistantes dans la littérature. Il existe de nombreux types d'interactions dans un écosystème impliquant des espèces différentes. On peut par exemple s'intéresser aux relations de pollinisation, l'ensemble des espèces est divisé en deux groupes, celui des insectes pollinisateurs et celui des plantes. Ces espèces ne peuvent interagir qu'avec des espèces de l'autre groupe. La relation est mutualiste, c'est à dire qu'elle bénéficie aux deux espèces. Ce type de réseau est dit bipartite.

1.2. État de l'art

Je renvoie vers[START_REF] Baudry | Estimation and model selection for model-based clustering with the conditional classification likelihood[END_REF] pour une discussion intéressante sur le critère ICL et au chapitre 8de Celeux et al. (2018) pour une introduction au critère de sélection de modèle dans les modèles de mélange.Je résume dans la table 1.1 les extensions de SBM aux collections de réseaux présentés en section 1.2.4 ainsi que leurs méthodes d'inférence, de sélection de modèle et le type de données sur lesquelles ces modèles sont appliqués.

1.3. Contributions de la thèse

2.1. Introduction

2.2. A multilevel stochastic block model

2.3. Statistical Inference

2.4. Illustration on simulated data

2.5. Application to the multilevel network issued from a television programs trade fair

2.6. Discussion

2.B. Proof of Proposition 2.2

2.D. Details of the ICL criterion

2.E. Stochastic Block Model for Generalized Multilevel Network

2.F. MLVSBM package Tutorial

2.G. Hard to Infer Levels: Benefits of the Multilevel Modeling

3.6. Model selection

3.10. Discussion

4.4. Moments of the robustness statistic

All the simulations and estimations in this section are done using the R package robber (Chabert-Liddell, 2021b)available on CRAN and documented at https://chabert-liddell.github.io/ro bber/.

4.6. Analysis of a collection of observed bipartite ecological networks

4.A. Proof for Section 4.4 (Moments of the robustness statistic)

Remerciements

Ma famille et mes amis et leur famille

Remerciements

Le jury, mes collègues et camarades

Acknowledgements

The authors would like to thank Julien Brailly for providing the dataset. This work was supported by a public grant as part of the Investissement d'avenir project, reference ANR-11-LABX-0056-LMH, LabEx LMH. This work was partially supported by the grant ANR-18-CE02-0010-01 of the French National Research Agency ANR (project EcoNet). This project received financial support from INRAE and CIRAD as part of the SEARS project funded by the GloFoods metaprogram. This work was presented and discussed within the framework of working days organized by the MIRES group (with the financial support of INRAE) and the GDR RESODIV (with the financial support of CNRS).

Acknowledgments

The authors would like to thank Stéphane Robin for his helpful advice. This work was supported by a public grant as part of the Investissement d'avenir project, reference ANR-11-LABX-0056-LMH, LabEx LMH. This work was partially supported by the grant ANR-18-CE02-0010-01 of the French National Research Agency ANR (project EcoNet).

Aknowledgement

The authors would like to thank Sonia Kefi, François Massol and Vincent Miele for their helpful advice. This work was supported by a public grant as part of the Investissement d'avenir project, reference ANR-11-LABX-0056-LMH, LabEx LMH. This work was partially supported by the grant ANR-18-CE02-0010-01 of the French National Research Agency ANR (project EcoNet).

3.D.2. Pairwise analysis of the advice networks

In this section, we analyze for each pair of networks if they share common structures. We fit each colSBM on all pairs of networks and compared the obtained BIC-L criterion to the one of two independent SBMs. The results are shown in The model selection criterion states that when considering networks two by two, the judges advice network does not share common structure with the other networks.

For lawyers and priests, the common structure is relevant only for δπ-colSBM , this M_PL for plants-pollinators with pollination (mutualistic) interactions, M_SD for plants-birds networks with seed dispersal (mutualistic) interactions.

We load the robber packages and the dataset which includes the 199 networks database.

library(robber) data("web_of_life")

Then we can compute the empirical robustness statistic and the one by biSBM for each networks, we give an example for uniform primary extinction sequences. To do so, we must first obtain the list of the biSBM parameters for each network:

4.B.2. Analyzing the link between richness, connectance and interaction type for empirical robustness

As can be seen in the next figure, the richness and connectance of the networks are highly dependent on the type of interaction. Parasitism networks tend to be small with high connectance and have a squared shape incidence matrix (n r ≈ n c ), while pollination networks tend to have much more pollinator species than plant species (n c >> n r ), also the largest networks have a low connectance. Finally seed-dispersal networks may have more plant species than bird species (n r > n c ).

Linear Model for Normalized biSBM Robustness

We fit linear models using the same covariates as for the empirical robustness (before normalization) but putting the normalized robustness statistics as the response variables instead. We still expect some effects of the connectance and richness on the normalized robustness, as larger and/or sparser networks may have different structures than smaller and/or denser ones.

fit <-lm(uniform.norm ~connectance + nr + nc + empty_row + empty_col, subset = index10ERno,data = tb_norm_stat) fit_type <lm(uniform.norm ~type*(connectance + nr + nc + empty_row + empty_col), subset = index10ERno,data = tb_norm_stat)

Let first notice in Table 4.2 that the adjusted R 2 s are much lower than the ones for the models explaining the empirical robustness. The additional effect of the interaction type is still present for the uniform primary extinction sequences but for the extinction sequences by block it is much harder to conclude (p -value ≈ .07).

4.B.4. Examining if networks are more robust to plant or animal extinctions

We can also compute the model parameters for the transposed networks, ie. the one for which primary extinctions occur on the column species and look at their impact on the row species. This makes sense for multualistic networks, e.g. pollination networks, as the extinction of a plant has an impact on the pollinators but also the extinction of a pollinator has an impact on the ability of a plant to be pollinized. Let (n , θ ) be the paramters of the transposed model, then:

δ qk = δ kq , ρ k = π k , π q = ρ q and n c = n r , n r = n c .

The normalized robustness of the transposed networks could be easily compute with