The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

UMLS::Similarity::jcn - Perl module for computing the semantic relatednessof concepts in the Unified Medical Language System (UMLS) using the method described by Jiang and Conrath (1997).

CITATION

 @inproceedings{JiangC97,
  Author = {Jiang, J. and Conrath, D.},
  Booktitle = {Proceedings on International Conference 
               on Research in Computational Linguistics},
  Pages = {pp. 19-33},
  Title = {Semantic similarity based on corpus statistics 
           and lexical taxonomy},
  Year = {1997}
 }

SYNOPSIS

  use UMLS::Interface;

  use UMLS::Similarity::jcn;

  my $icpropagation = "samples/icpropagation";

  my %option_hash = ();

  $option_hash{"propagation"} = $icpropagation;

  my $umls = UMLS::Interface->new(\%option_hash); 

  die "Unable to create UMLS::Interface object.\n" if(!$umls);

  my $jcn = UMLS::Similarity::jcn->new($umls);

  die "Unable to create measure object.\n" if(!$jcn);

  my $cui1 = "C0005767";

  my $cui2 = "C0007634";

  @ts1 = $umls->getTermList($cui1);

  my $term1 = pop @ts1;

  @ts2 = $umls->getTermList($cui2);

  my $term2 = pop @ts2;

  my $value = $jcn->getRelatedness($cui1, $cui2);

  print "The similarity between $cui1 ($term1) and $cui2 ($term2) is $value\n";

DESCRIPTION

This module computes the semantic similarity of two concepts in the UMLS according to a method described by Jiang and Conrath (1997). This measure is based on a combination of using edge counts in the UMLS 'is-a' hierarchy and using the information content values of the concepts, as describedin the paper by Jiang and Conrath. Their measure, however, computes values that indicate the semantic distance between words (as opposed to their semantic similarity). In this implementation of the measure we invert the value so as to obtain a measure of semantic relatedness. Other issues that arise due to this inversion (such as handling of zero values in the denominator) have been taken care of as special cases.

The IC of a concept is defined as the negative log of the probabilty of the concept.

To use this measure, a propagation file containing the probability of a CUI for each of the CUIs from the source(s) specified in the configuration file. The format for this file is as follows:

 C0000039<>0.00003951
 C0000052<>0.00003951
 C0000084<>0.00003951
 C0000096<>0.00003951

A larger of example of this file can be found in the icpropagation file in the samples/ directory.

A propagation file can be created using the create-icfrequency.pl and the create-icpropagation.pl programs in the utils/ directory. The create-icfrequency.pl program takes plain text and returns a list of CUIs that are mapped to the text and the CUIs frequency counts. This file can then be used by the create-icpropagation.pl program to create a file containing a list of CUIs and their probability counts, or used directly by the umls-similarity.pl program which will calculate the probability of a concept on the fly.

The probability of each of the CUIs is dependendent on the set of source(s) and relations specified in the configuration file - You can not mix and match.

PROPAGATION

The Information Content (IC) is defined as the negative log of the probability of a concept. The probability of a concept, c, is determine by summing the probability of the concept (P(c)) ocurring in some text plus the probability its decendants (P(d)) occuring in some text:

P(c*) = P(c) + \sum_{d\exists decendant(c)} P(d)

The initial probability of a concept (P(c)) and its decendants (P(d)) is obtained by dividing the number of times a concept is seen in the corpus (freq(d)) by the total number of concepts (N):

P(d) = freq(d) / N

Not all of the concepts in the taxonomy will be seen in the corpus. We have the option to use Laplace smoothing, where the frequency count of each of the concepts in the taxonomy is incremented by one. The advantage of doing this is that it avoides having a concept that has a probability of zero. The disadvantage is that it can shift the overall probability mass of the concepts from what is actually seen in the corpus.

USAGE

The semantic relatedness modules in this distribution are built as classes that expose the following methods: new() getRelatedness()

TYPICAL USAGE EXAMPLES

To create an object of the jcn measure, we would have the following lines of code in the perl program.

   use UMLS::Similarity::jcn;
   $measure = UMLS::Similarity::jcn->new($interface);

The reference of the initialized object is stored in the scalar variable '$measure'. '$interface' contains an interface object that should have been created earlier in the program (UMLS-Interface).

If the 'new' method is unable to create the object, '$measure' would be undefined.

To find the semantic relatedness of the concept 'blood' (C0005767) and the concept 'cell' (C0007634) using the measure, we would write the following piece of code:

   $relatedness = $measure->getRelatedness('C0005767', 'C0007634');

SEE ALSO

perl(1), UMLS::Interface

perl(1), UMLS::Similarity(3)

CONTACT US

  If you have any trouble installing and using UMLS-Similarity, 
  please contact us via the users mailing list :

      umls-similarity@yahoogroups.com

  You can join this group by going to:

      http://tech.groups.yahoo.com/group/umls-similarity/

  You may also contact us directly if you prefer :

      Bridget T. McInnes: bthomson at cs.umn.edu 

      Ted Pedersen : tpederse at d.umn.edu

AUTHORS

  Bridget T McInnes <bthomson at cs.umn.edu>
  Siddharth Patwardhan <sidd at cs.utah.edu>
  Serguei Pakhomov <pakh0002 at umn.edu>
  Ted Pedersen <tpederse at d.umn.edu>

COPYRIGHT AND LICENSE

Copyright 2004-2010 by Bridget T McInnes, Siddharth Patwardhan, Serguei Pakhomov, Ying Liu and Ted Pedersen

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.