Skip to content

Commit

Permalink
1. Mentioned in bold that Metamap binary path should be absolute. 2.
Browse files Browse the repository at this point in the history
spelling correction
  • Loading branch information
kaushikacharya committed Jul 21, 2018
1 parent 9050452 commit f43dd3b
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,13 @@ To start you must create a MetaMap instance from the pymetamap package.
>>> mm = MetaMap.get_instance('/opt/public_mm/bin/metamap12')

You must supply the metamap binary to ``get_instance()`` in order to
extract concepts. Depending on where you installed MetaMap and depending on the version you are using, you will need to change the ``/opt/public_mm/bin/metamap12`` to the correct location. For example, if you installed the 2016 version of MetaMap, then the binary will be called ``metamap16``.
extract concepts. Depending on where you installed MetaMap and depending on the version you are using, you will need to change the ``/opt/public_mm/bin/metamap12`` to the correct location.
For example, if you installed the 2016 version of MetaMap, then the binary will be called ``metamap16``.

**Note:** Metamap binary path should be absolute.

To extract concepts from a sentence use the ``extract_concepts()``
method. This method taks a list of sentences as input and will return
method. This method takes a list of sentences as input and will return
a list of Concept objects.

::
Expand All @@ -42,7 +45,7 @@ a list of Concept objects.
Concept(index='1', mm='MM', score='14.64', preferred_name='Myocardial Infarction', cui='C0027051', semtypes='[dsyn]', trigger='["Heart attack"-tx-1-"Heart Attack"]', location='TX', pos_info='1:12', tree_codes='C14.280.647.500;C14.907.585.500')
Concept(index='2', mm='MM', score='13.22', preferred_name='Myocardial Infarction', cui='C0027051', semtypes='[dsyn]', trigger='["Heart attack"-tx-1-"heart attack"]', location='TX', pos_info='17:12', tree_codes='C14.280.647.500;C14.907.585.500')

This example shows two seperate concepts extracted via MetaMap from two
This example shows two separate concepts extracted via MetaMap from two
different sentences (sentence 1 and sentence 2).

More Information
Expand Down

0 comments on commit f43dd3b

Please sign in to comment.