How to treat $ in XML?

dandee

New Member
ElementTree throws an exception for \[code\]<PRP$>\[/code\]:\[code\]Traceback (most recent call last): File "<stdin>", line 1, in <module> File "<stdin>", line 3, in xml File "/usr/lib/python2.7/xml/etree/ElementTree.py", line 1301, in XML parser.feed(text) File "/usr/lib/python2.7/xml/etree/ElementTree.py", line 1643, in feed self._raiseerror(v) File "/usr/lib/python2.7/xml/etree/ElementTree.py", line 1507, in _raiseerror raise errxml.etree.ElementTree.ParseError: not well-formed (invalid token): line 28, column 14\[/code\]I got this output from Stanford NLP package. Is it truly malformed? Wikipedia and other sources dont mention it.How to solve this? I would want to replace \[code\]$\[/code\] by its corresponding entity if I knew what it was.
 
Back
Top