ensembl-hive  2.6
Bio::EnsEMBL::TopLevelAssemblyMapper Class Reference

Public Member Functions

public Bio::EnsEMBL::DBSQL::TopLevelAssemblyMapper new ()
 
public adaptor ()
 
public List map ()
 
public void flush ()
 
public List fastmap ()
 
public Bio::EnsEMBL::CoordSystem assembled_CoordSystem ()
 
public Bio::EnsEMBL::CoordSystem component_CoordSystem ()
 
protected _list ()
 
public List list_seq_regions ()
 
public List list_ids ()
 

Detailed Description

Synopsis

$asma = $db->get_AssemblyMapperAdaptor();
$csa = $db->get_CoordSystemAdaptor();
my $toplevel = $cs_adaptor->fetch_by_name('toplevel');
my $ctg_cs = $cs_adaptor->fetch_by_name('contig');
$asm_mapper = $map_adaptor->fetch_by_CoordSystems( $toplevel, $ctg_cs );
# map to toplevel coord system for this region
@chr_coords =
$asm_mapper->map( 'AL30421.1.200.92341', 100, 10000, -1, $ctg_cs );
# list toplevel seq_region_ids for this region
@chr_ids =
$asm_mapper->list_ids( 'AL30421.1.200.92341', 1, 1000, -1,
$ctg_cs );

Description

The TopLevelAssemblyMapper performs mapping between a provided
coordinate system and the toplevel pseudo cooordinate system.  The
toplevel coordinate system is not a real coordinate system, but
represents the highest coordinate system that can be mapped to in a
given region.  It is only possible to perform unidirectional mapping
using this mapper, because it does not make sense to map from the
toplevel coordinate system to another coordinate system.

Definition at line 40 of file TopLevelAssemblyMapper.pm.

Member Function Documentation

◆ _list()

protected Bio::EnsEMBL::TopLevelAssemblyMapper::_list ( )

Undocumented method

Code:
click to view

◆ adaptor()

public Bio::EnsEMBL::TopLevelAssemblyMapper::adaptor ( )

Undocumented method

Code:
click to view

◆ assembled_CoordSystem()

public Bio::EnsEMBL::CoordSystem Bio::EnsEMBL::TopLevelAssemblyMapper::assembled_CoordSystem ( )
  Arg [1]    : none
  Example    :
$cs = $mapper->assembled_CoordSystem
  Description: Retrieves the assembled CoordSystem from this mapper
  Returntype : Bio::EnsEMBL::CoordSystem
  Exceptions : none
  Caller     : internal, AssemblyMapperAdaptor
  Status     : Stable
 
Code:
click to view

◆ component_CoordSystem()

public Bio::EnsEMBL::CoordSystem Bio::EnsEMBL::TopLevelAssemblyMapper::component_CoordSystem ( )
  Arg [1]    : none
  Example    :
$cs = $mapper->component_CoordSystem
  Description: Retrieves the component CoordSystem from this  mapper
  Returntype : Bio::EnsEMBL::CoordSystem
  Exceptions : none
  Caller     : internal, AssemblyMapperAdaptor
  Status     : Stable
 
Code:
click to view

◆ fastmap()

public List Bio::EnsEMBL::TopLevelAssemblyMapper::fastmap ( )
  Arg [1]    : string $frm_seq_region
               The name of the sequence region to transform FROM
  Arg [2]    : int $frm_start
               The start of the region to transform FROM
  Arg [3]    : int $frm_end
               The end of the region to transform FROM
  Arg [4]    : int $strand
               The strand of the region to transform FROM
  Arg [5]    : Bio::EnsEMBL::CoordSystem
               The coordinate system to transform FROM
  Example    :
@coords = $mapper->fastmap('X', 1_000_000, 2_000_000,
1, $chr_cs);
  Description: Transforms coordinates from one coordinate system
               to another.
  Returntype : List of Bio::EnsEMBL::Mapper::Coordinate and/or
               Bio::EnsEMBL::Mapper:Gap objects
  Exceptions : thrown if if the specified TO coordinate system is not one
               of the coordinate systems associated with this mapper
  Caller     : general
  Status     : Stable
 
Code:
click to view

◆ flush()

public void Bio::EnsEMBL::TopLevelAssemblyMapper::flush ( )
  Args       : none
  Example    :
none
  Description: polymorphism with AssemblyMapper, does nothing
  Returntype : none
  Exceptions : none
  Status     : Stable
 
Code:
click to view

◆ list_ids()

public List Bio::EnsEMBL::TopLevelAssemblyMapper::list_ids ( )
  Arg [1]    : string $frm_seq_region
               The name of the sequence region of interest.
  Arg [2]    : int $frm_start
               The start of the region of interest
  Arg [3]    : int $frm_end
               The end of the region to transform of interest
  Arg [5]    : Bio::EnsEMBL::CoordSystem $frm_cs
               The coordinate system to obtain overlapping ids of
  Example    :
foreach $id ($asm_mapper->list_ids('X',1,1000,$chr_cs)) {...}
  Description: Retrieves a list of overlapping seq_region internal identifiers
               of another coordinate system.  This is the same as the
               list_seq_regions method but uses internal identfiers rather 
               than seq_region strings
  Returntype : List of ints
  Exceptions : thrown if the from CoordSystem is the toplevel coord system
               thrown if the from CoordSystem is not the one used in the mapper
  Caller     : general
  Status     : Stable
 
Code:
click to view

◆ list_seq_regions()

public List Bio::EnsEMBL::TopLevelAssemblyMapper::list_seq_regions ( )
  Arg [1]    : string $frm_seq_region
               The name of the sequence region of interest
  Arg [2]    : int $frm_start
               The start of the region of interest
  Arg [3]    : int $frm_end
               The end of the region to transform of interest
  Arg [5]    : Bio::EnsEMBL::CoordSystem $frm_cs
               The coordinate system to obtain overlapping ids of
  Example    :
foreach $id ($asm_mapper->list_ids('X',1,1000,$ctg_cs)) {...}
  Description: Retrieves a list of overlapping seq_region names
               of another coordinate system.  This is the same as the
               list_ids method but uses seq_region names rather internal ids
  Returntype : List of strings
  Exceptions : none
  Caller     : general
  Status     : Stable
 
Code:
click to view

◆ map()

public List Bio::EnsEMBL::TopLevelAssemblyMapper::map ( )
  Arg [1]    : string $frm_seq_region
               The name of the sequence region to transform FROM
  Arg [2]    : int $frm_start
               The start of the region to transform FROM
  Arg [3]    : int $frm_end
               The end of the region to transform FROM
  Arg [4]    : int $strand
               The strand of the region to transform FROM
  Arg [5]    : Bio::EnsEMBL::CoordSystem
               The coordinate system to transform FROM
  Arg [6]    : if set will do a fastmap
  Arg [7]    : (optional) dummy placeholder to keep the interface
               consistent across different mappers
  Arg [8]    : (optional) boolean
               Whether or not to include the original coordinates
  Example    :
@coords = $mapper->map('X', 1_000_000, 2_000_000,
1, $chr_cs);
  Description: Transforms coordinates from one coordinate system
               to another.
  Returntype : List of Bio::EnsEMBL::Mapper::Coordinate and/or
               Bio::EnsEMBL::Mapper:Gap objects
  Exceptions : thrown if if the specified TO coordinate system is not one
               of the coordinate systems associated with this mapper
  Caller     : general
  Status     : Stable
 
Code:
click to view

◆ new()

public Bio::EnsEMBL::DBSQL::TopLevelAssemblyMapper Bio::EnsEMBL::TopLevelAssemblyMapper::new ( )
  Arg [1]    : Bio::EnsEMBL::DBAdaptor $dbadaptor the adaptor for
               the database this mapper is using.
  Arg [2]    : Toplevel CoordSystem
  Arg [3]    : Other CoordSystem
  Description: Creates a new TopLevelAssemblyMapper object
  Returntype : Bio::EnsEMBL::DBSQL::TopLevelAssemblyMapper
  Exceptions : throws if any of the 3 arguments are missing/ not 
             : of the correct type.
  Caller     : Bio::EnsEMBL::DBSQL::AssemblyMapperAdaptor
  Status     : Stable
 
Code:
click to view

The documentation for this class was generated from the following file:
Bio::EnsEMBL::TopLevelAssemblyMapper::component_CoordSystem
public Bio::EnsEMBL::CoordSystem component_CoordSystem()
Bio::EnsEMBL::TopLevelAssemblyMapper::flush
public void flush()
Bio::EnsEMBL::TopLevelAssemblyMapper::list_ids
public List list_ids()
Bio::EnsEMBL::DBSQL::DBAdaptor
Definition: DBAdaptor.pm:40
Bio::EnsEMBL::Mapper::Coordinate
Definition: Coordinate.pm:14
Bio::EnsEMBL::TopLevelAssemblyMapper::fastmap
public List fastmap()
Bio::EnsEMBL::TopLevelAssemblyMapper::adaptor
public adaptor()
Bio::EnsEMBL::TopLevelAssemblyMapper::_list
protected _list()
Bio::EnsEMBL::TopLevelAssemblyMapper::map
public List map()
Bio::EnsEMBL::TopLevelAssemblyMapper::assembled_CoordSystem
public Bio::EnsEMBL::CoordSystem assembled_CoordSystem()
Bio::EnsEMBL::TopLevelAssemblyMapper::list_seq_regions
public List list_seq_regions()
Bio::EnsEMBL::Mapper::Coordinate::new
public new()
Bio::EnsEMBL::DBSQL::DBAdaptor::new
public Bio::EnsEMBL::DBSQL::DBAdaptor new()