# Degree and weight preserving randomisation in networks

I have a network in which nodes are highly interconnected (250 nodes where 90% of the nodes have degree = 249). The connections are weighted with a normalised index that goes from 0 to 1, where 1 means a strong connection and values close to 0 identify weak connections. The weight distribution of the network is right-skewed, with most edges having proximity close to 0. I am trying to set a non-arbitrary threshold to decide which edges to retain; in the extant literature it seems a consolidated practice to choose a threshold arbitrarily and I can't find any standard method that allows to set a threshold of this kind (for instance, basing on the weight distribution of the edges.

Is there an empirical method to set such threshold?

I am also using degree-preserving randomisation tests in order to compare the network-level characteristics to the distribution of the same characteristics extracted from the randomised graphs. However, the randomised networks are unweighted.

Is there a way to obtain weighted random networks using degree preserving randomisation? And secondly, is there a statistical test I can perform in order to select the "significant" connections (those that are observed consistently both in the empirical network and randomised networks)?

It isn't always possible to (non-trivially) randomise weighted edges while preserving vertices' strengths (that is, the sum of weights of edges incident with each vertex). For example, consider the weighted graph $$G$$ with vertex set $$\{a,b,c,d,e\}$$, edge set $$\{\{a,b\},\{b,c\},\{c,d\},\{d,e\}\}$$, and edge weights $$w(\{a,b\})=1$$, $$w(\{b,c\})=2$$, $$w(\{c,d\})=3$$ and $$w(\{d,e\})=4$$. Every rewiring of $$G$$ changes the strengths of at least one of $$b$$, $$c$$ and $$d$$. Thus, every strength-preserving "randomisation" of $$G$$ is isomorphic to $$G$$.
That said, strength-preserving randomisation may be possible in your case if some edges share the same weights. Rewiring such edges randomly will preserve vertices' strengths and (probably) deliver a non-isomorphic graph. You could do this by stratifying the edge set by edges' weights and then randomly swapping the tail vertices for pairs of edges (e.g., $$v_1$$ and $$v_2$$ for edges $$\{u_1,v_1\}$$ and $$\{u_2,v_2\}$$) in each stratum.