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

NAME

Bio::Affymetrix::CEL- parse Affymetrix CEL files

SYNOPSIS

use Bio::Affymetrix::CEL;

# Parse the CDF file

my $cel=new Bio::Affymetrix::CEL();

$cel->parse_from_file("foo.cel");

# Print out all of the intensities for each square

for (my $x=0;$x<scalar(@{$cel->intensity_map()});$x++) { for (my $y=0;$y<scalar(@{cel->intensity_map()->[$x]});$y++) { print join(",",($x,$y,$cel->intensity_map->[$x][$y]->[0])."\n"; } }

DESCRIPTION

The Affymetrix microarray system produces files in a variety of formats. If this means nothing to you, these modules are probably not for you :). This module parses CEL files. Use this module if you want to find out about the results for individual probes on an array.

All of the Bio::Affymetrix modules parse a file entirely into memory. You therefore need enough memory to hold these objects. For some applications, parsing as a stream may be more appropriate- hopefully the source to these modules will give enough clues to make this an easy task. This module takes lots of memory due to the way Perl stores arrays. If you are writing a program that uses many CEL files, delete each CEL file once you have the information you need from it.

HINTS

You fill the object filled with data using the parse_from_filehandle, parse_from_string or parse_from_file routines. You can get/set various statistics using methods on the object.

The key method is intensity_map. This returns a reference to a 2D array of parameters for each square.

NOTES

REFERENCE

Modules were written with the official Affymetrix documentation, which can be located at http://www.affymetrix.com/support/developer/AffxFileFormats.ZIP

COMPATIBILITY

This module can parse the CEL files produced by the Affymetrix software MAS 5 and GCOS.

TODO

Writing CEL files as well as reading them.

COPYRIGHT

Copyright (C) 2005 by Nick James, David J Craigon, NASC, The University of Nottingham

This module is free software. You can copy or redistribute it under the same terms as Perl itself.

Affymetrix is a registered trademark of Affymetrix Inc., Santa Clara, California, USA.

AUTHORS

Nick James (nick at arabidopsis.info)

David J Craigon (david at arabidopsis.info)

Nottingham Arabidopsis Stock Centre (http://arabidopsis.info), University of Nottingham.

METHODS

new

  Arg [0]    : none
  Example    : my $cel=new Bio::Affymetrix::CEL();
  Description: constructor for CEL object
  Returntype : new Bio::Affmetrix::CEL object
  Exceptions : none
  Caller     : general

original_version Arg [0] : none Example : my $version=$cel->original_version() Description: Returns the version of the CEL file parsed. Encoded in file. Returntype : string Exceptions : none Caller : general

original_format Arg [0] : none Example : my $format=$cel->original_format() Description: Returns the format of the CEL file parsed. Currently MAS5 or XDA Returntype : string ("MAS5" or "XDA") Exceptions : none Caller : general

original_rows Arg [0] : none Example : my $rows=$cel->orignal_rows() Description: Get the number of rows originally reported on this chip Returntype : integer Exceptions : none Caller : general

original_cols Arg [0] : none Example : my $cols=$cel->original_cols() Description: Get the number of cols originally reported on this chip Returntype : integer Exceptions : none Caller : general

x_offset Arg [1] : integer $x_offset (optional) Example : my $x_offset=$cel->x_offset() Description: Get/Set the x offset. This is always 0 when parsed from a genuine CEL file. Only available in MAS5 CEL files Returntype : integer Exceptions : none Caller : general

y_offset Arg [1] : integer $y_offset (optional) Example : my $y_offset=$cel->y_offset() Description: Get/Set the y offset. This is always 0 when parsed from a genuine CEL file. Only available in MAS5 CEL files. Returntype : integer Exceptions : none Caller : general

grid_corner_ul Arg [1] : integer $grid_corner_ul (optional) Example : my $grid_corner_ul=$cel->grid_corner_ul() Description: Get/set the XY coordinates of the upper left grid corner in pixel coordinates. Only available in MAS5 CEL files. Returntype : integer Exceptions : none Caller : general

grid_corner_ur Arg [1] : integer $grid_corner_ur (optional) Example : my $grid_corner_ur=$cel->grid_corner_ur() Description: Get/set the XY coordinates of the upper right grid corner in pixel coordinates. Only available in MAS5 CEL files. Returntype : integer Exceptions : none Caller : general

grid_corner_lr Arg [1] : integer $grid_corner_lr (optional) Example : my $grid_corner_lr=$cel->grid_corner_lr() Description: Get/set the XY coordinates of the lower right grid corner in pixel coordinates. Only available in MAS5 CEL files. Returntype : integer Exceptions : none Caller : general

grid_corner_ll Arg [1] : integer $grid_corner_ll (optional) Example : my $grid_corner_ll=$cel->grid_corner_ll() Description: Get/set the XY coordinates of the lower left grid corner in pixel coordinates. Only available in MAS5 CEL files. Returntype : integer Exceptions : none Caller : general

axis_invert_x Arg [1] : boolean $axis_invert_x (optional) Example : my $axis_invert_x=$cel->axis_invert_x() Description: Get/set whether the X axis is inverted. Always false in genuine CEL files Only available in MAS5 CEL files. Returntype : boolean Exceptions : none Caller : general

axis_invert_x Arg [1] : boolean $axis_invert_y (optional) Example : my $axis_invert_y=$cel->axis_invert_y() Description: Get/set whether the Y axis is inverted. Always false in genuine CEL files Only available in MAS5 CEL files. Returntype : boolean Exceptions : none Caller : general

swap_xy Arg [1] : boolean $swap_xy (optional) Example : my $swap_xy=$cel->swap_xy() Description: Get/set whether the X and Y axis are swapped. Always false in genuine CEL files Only available in MAS5 CEL files. Returntype : boolean Exceptions : none Caller : general

original_file_name

  Arg [0]    :  none
  Example    :  my $cel_file_name=$cel->original_file_name();
  Description:  If this object was created using parse_from_file, the original filename. Otherwise undef.
  Returntype :  string
  Exceptions :  none
  Caller     :  general

algorithm_name

  Arg [1]    :  string $algorithm_name (optional)
  Example    :  my $algorithm_name=$cel->algorithm_name();
  Description:  Get/set the algorithm name that created this CEL file.
  Returntype :  string
  Exceptions :  none
  Caller     :  general

algorithm_params

  Arg [1]    :  hashref $algorithm_params (optional)
  Example    :  my %algorithm_params=%{$cel->algorithm_params()};

# Print margin of cells ignored for calculating signal

print $algorithm_params("CellMargin");

  Description:  Get/set the algorithm parameters for the CEL file creation
  Returntype :  hashref
  Exceptions :  none
  Caller     :  general

intensity_map Arg [1] : optional arrayref Example : print $cel->intensity_map()->[0][0]->[0] Description: Returns an reference to a 2D array. Each value in this array is another arrayref containing (in order): Mean intensity, Standard Deviation of intensity, number of pixels used in the calculation, a flag stating whether the user has masked this square, a flag stating whether the software has called this square an outlier. Returntype : 2d arrayref Exceptions : none Caller : general

parse_from_string

  Arg [1]    :  string
  Example    :  $cel->parse_from_string($cel_file_in_a_string);
  Description:  Parse a CEL file from a buffer in memory
  Returntype :  none
  Exceptions :  none
  Caller     :  general

parse_from_file

  Arg [1]    :  string
  Example    :  $cel->parse_from_file($cel_filename);
  Description:  Parse a CEL file from a file
  Returntype :  none
  Exceptions :  dies if cannot open file
  Caller     :  general

parse_from_filehandle

  Arg [1]    :  reference to filehandle
  Example    :  $cel->parse_from_filehandle(\*STDIN);
  Description:  Parse a CEL file from a filehandle
  Returntype :  none
  Exceptions :  none
  Caller     :  general