Commit 0c03089d authored by Andrew Cohen's avatar Andrew Cohen
Browse files

new normalizing denominator?

parent 14a34e61
......@@ -22,5 +22,6 @@ end
N=GetCount({'N'});
nwd = (log2(max(fw))-log2(fX)) / (log2(N)-log2(min(fw))); % III.3 from arxiv
% normalize for cardinality
% nwd = nwd/(length(words)-1);
% nwd=(log2(max(fw))-log2(fX))/( log2(N)-log2(max(fexclude)) );
......@@ -3,18 +3,6 @@ tic
% goNWD
%
%
% %
% words1={'Upsal','Carpenter','Allen Lane','St Martins','Highland','Chestnut Hill West'}
% words2={'Stenton','Sedgwick','Mount Airy','Wyndmoor','Gravers',' Chestnut Hill East'}
% words2={'Fox Chase','Ryers','Cheltenham','Lawndale','Olney'}
% words1={'148991' '327941' '195539' '704017' '260207' '988649'}
% words2={'865845' '683546' '754352' '784163' '613252' '796525'}
% words1={'29' '37' '59' '71' '97' '23' }
% words2={'88' '44' '12' '56' '6' '62'}
% words1={'Gerald Ford' 'Jimmy Carter' 'Ronald Reagan' 'George H. W. Bush' 'Bill Clinton' 'George W. Bush'}
% words2={'Mitt Romney' 'John McCain' 'John Kerry' 'Al Gore' 'Bob Dole' 'Michael Dukakis'}
%
strServer='wikipedia'
......@@ -23,7 +11,7 @@ words2={'lion','tiger','bear','monkey','zebra','elephant','aardvark','lamb','fox
[d1,d2]=GetDistances(words1,words2);
idx=getDistancesPairs(words1,words2);
words1={'red','orange','yellow','green','blue','indigo','violet','purple','tan','white'}
words1={'red','orange','yellow','green','blue','indigo','violet','purple','cyan','white'}
words2={'square','circle','rectangle','ellipse','triangle','rhombus'}
[d1,d2]=GetDistances(words1,words2);
idx=getDistancesPairs(words1,words2);
......
This diff is collapsed.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment