This example treats the input graph as a weighted, undirected network and outputs only nodes with degree range 3 or greater.
SQL Call
SELECT * FROM LocalClusteringCoefficient ( ON trade AS Edges PARTITION BY fromid ON country AS Vertices PARTITION BY countryid USING TargetKey ('toid') Directed ('f') EdgeWeight ('tradeweight') DegreeRange ('[3:]') Accumulate ('countryid', 'name') ) AS dt ORDER BY countryid;
Output
countryid name degree tri_cnt cc w_cc --------- ---- ------ ------- -- ------- 1 usa 4 6 1 0.44642 3 uk 4 6 1 0.44642
Download a zip file of all examples and a SQL script file that creates their input tables.