Hi all,
I have 271 unique forum IDs and need to calculate the Euclidean distance between each forum ACROSS all 16 organizational types.
If I use code [matrix diss O1 = orgtype1, L2], I get the Euclidean distance between each forum for Org 1, but how do I do this across all org types such that I have one matrix of Euclidean distances between each forum across all 16 (i.e., sum 1-16, (difference)^2)^1/2
Thank you very much
----------------------- copy starting from the next line -----------------------
[CODE]
* Example generated by -dataex-. To install: ssc install dataex
clear
input float(forumid orgtype1 orgtype2 orgtype3 orgtype4 orgtype5 orgtype6 orgtype7 orgtype8 orgtype9 orgtype10 orgtype11 orgtype12 orgtype13 orgtype14 orgtype15 orgtype16)
102 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0
103 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
104 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
106 0 0 0 .16666667 .7777778 0 .05555556 0 0 0 0 0 0 0 0 0
107 0 0 0 0 .5 0 0 0 0 0 0 0 0 0 0 0
109 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0
110 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0
111 0 0 0 0 0 0 1 0 0 0
Related Posts with Euclidean distance matrix
ANOVA REPEATE MEASURES - HOW TO INTERPRET CONTRADICTORY RESULTS BETWEEN ANOVA AND MULTIPLE PAIRWISE COMPARISONS (post hoc)?Good mornig to everybody. HOW TO INTERPRET CONTRADICTORY RESULTS BETWEEN ANOVA AND MULTIPLE PAIRWIS…
merging data files to create a large panel data by VDS_Id and SUR_MON_YRhere is data below Code: * Example generated by -dataex-. To install: ssc install dataex clear inpu…
xtabond2 vs xtreg / xtregarDear Stata users, I have always assumed that in the presence of serial autocorrelation and assumpti…
ANOVA REPEATE MEASURES - HOW TO INTERPRET CONTRADICTORY RESULTS BETWEEN ANOVA AND MULTIPLE PAIRWISE COMPARISONS (post hoc)?Good mornig to everybody. 1)HOW TO INTERPRET CONTRADICTORY RESULTS BETWEEN ANOVA AND MULTIPLE PAIRW…
Time Series Graph Percentage Deviations from TrendHello, I am currently working on time series analysis, trying to identify the effect of an increase…
Subscribe to:
Post Comments (Atom)
0 Response to Euclidean distance matrix
Post a Comment