Provided by: librefdb-perlmod-perl_1.2-2_all bug


       RefDB::Pubmed - Perl extension for converting Pubmed bibliographic data to RIS


         use RefDB::Pubmed;
         my $infile = "-";

         my $pm = new RefDB::Pubmed;


         while ((my $set = $pm->next_pubmed_set())) {


       RefDB::Pubmed allows one to convert Pubmed/Medline bibliographic data to the RIS format
       understood by RefDB and most other bibliographic software. Data can be provided as a
       string or they can be read from a file/stream.


       Send bug reports, questions, and comments to the refdb-users mailing list at:

       For list information and archives, please visit:


       Markus Hoenicka,


       This module is part of the RefDB package, a reference manager and bibliography tool for
       markup languages. Please visit for further information.

PMSet package

       This helper package defines methods to deal with a Pubmed dataset

       Title   : new

       Usage   : $set = new PMset();

       Function: Creates a new PMset object

       Title   : parse_pmset

       Usage   : $set->parse_pmset();

       Function: parses the raw tagged Pubmed data

       Title   : convert_pmset()

       Usage   : $set->convert_pmset()

       Function: Converts the parsed data to RIS data

       Title   : dump_pmset_as_ris

       Usage   : $set->dump_pmset_as_ris()

       Function: Dumps the data as a valid RIS set

       Title   : dump_pmset_as_pm

       Usage   : $set->dump_pmset_as_pm()

       Function: dumps the parsed data as a Pubmed set. The result differs from the input in that
       each tag with its associated data is always in a single line whereas the input data may
       contain continued lines w/o a tag. You can use this function to normalize the Pubmed
       tagged data.

       Title   : _convert_tag

       Usage   : $self->_convert_tag($key, $string);

       Function: Converts a Pubmed tag line to RIS and adds the result to a list

       Argument: string containing the tag, something like 'KW  - '
                 string containing the data associated with the tag

       Title   : _split_mesh

       Usage   : $self->_split_mesh($string);

       Function: splits a Pubmed MH line into one or more RIS KW lines

       Argument: string containing the data associated with the MH tag

       Title   : set_print_unmapped

       Usage   : $pm->set_print_unmapped(1)

       Function: switch on or off printing of unmapped Pubmed tags

       Argument: 0 (zero) to switch off or non-zero to switch on

       Title   : set_converter

       Usage   : $pm->set_converter("from_enc", "to_enc")

       Function: creates the iconv character encoding converter to be used

       Arguments: from_enc, to_enc: the encoding of the source data and of the output data,

       Title   : add_raw_line

       Usage   : $set->add_raw_line($_)

       Function: adds a raw Pubmed line to the internal list

       Argument: string containing a full Pubmed line

Pubmed package

       This package defines functions to deal with collections of Pubmed datasets

       Title   : new

       Usage   : $pm = new RefDB::Pubmed();

       Function: Creates a new Pubmed object

       Title   : in

       Usage   : $pm->in($filename)

       Function: Opens a file or input stream for reading

       Returns : A filehandle or undef if the stream could not be opened

       Argument: The path of a file or the name of an input stream

       Title   : string

       Usage   : $pm->string($string)

       Function: Accepts an input string for parsing

       Returns : 1 if Pubmed data, 0 if not Argument: A string containing input data

       Title   : next_pubmed_set

       Usage   : $pm->next_pubmed_set()

       Function: Reads the next Pubmed dataset

       Returns : A PMset containing the raw Pubmed tagged data, or undef if no data available

       Title   : set_print_unmapped

       Usage   : $pm->set_print_unmapped(1)

       Function: switch on or off printing of unmapped Pubmed tags

       Argument: 0 (zero) to switch off or non-zero to switch on

       Title   : set_encodings

       Usage   : $pm->set_encodings("from_enc", "to_enc")

       Function: set encodings of input and output data

       Argument: from_enc, to_enc according to "man iconv_open"