Scénario de test & Cas d'usage
Creation of a transactional dataset with a clear closed loop (A->B->C->A) and a separate legitimate transaction path.
| 1 | DATA mycas.transactions; INPUT from_acc $ to_acc $ amount; DATALINES; |
| 2 | ACC_A ACC_B 10000 |
| 3 | ACC_B ACC_C 9500 |
| 4 | ACC_C ACC_A 9000 |
| 5 | ACC_X ACC_Y 50 |
| 6 | ACC_Y ACC_Z 50 |
| 7 | ; RUN; |
| 1 | PROC CAS; |
| 2 | network.community / |
| 3 | direction="DIRECTED" |
| 4 | links={name="transactions", vars={"from_acc", "to_acc", "amount"}} |
| 5 | outNodes={name="account_communities", replace=true}; |
| 6 | QUIT; |
| 1 | |
| 2 | PROC PRINT |
| 3 | DATA=mycas.account_communities; |
| 4 | where _community_ ne .; |
| 5 | |
| 6 | RUN; |
| 7 |
The accounts ACC_A, ACC_B, and ACC_C should be grouped into a single unique community ID due to the strong directional circular flow, distinguishing them from the linear flow of X->Y->Z.