The new() class method constructs a new Bio::SeqIO object. The returned object can be used to retrieve or print Seq objects. new() accepts the following parameters:
-file
A file path to be opened for reading or writing. The usual Perl conventions apply:
'file' # open file for reading
'>file' # open file for writing
'>>file' # open file for appending
'+<file' # open file read/write
'command |' # open a pipe from the command
'| command' # open a pipe to the command
-fh
You may provide new() with a previously-opened filehandle. For example, to read from STDIN:
$seqIO = Bio::SeqIO->new(-fh => \*STDIN);
Partager