Package mvpa :: Package featsel :: Module helpers :: Class FixedNElementTailSelector

[hide private]
[frames] | no frames]

# Class FixedNElementTailSelector

source code

Given a sequence, provide set of IDs for a fixed number of to be selected elements.

Nested Classes | [hide private]

Inherited from `misc.state.ClassWithCollections`: `__metaclass__`

Instance Methods | [hide private]

__init__(self, nelements, **kwargs) Cheap initialization. | source code

__repr__(self) String definition of the object of ClassWithCollections object | source code

_getNElements(self, seq) In derived classes has to return the number of elements to be processed given a sequence values forming the distribution. | source code

_setNElements(self, nelements) | source code

Inherited from `TailSelector`: `__call__` Inherited from `TailSelector` (private): `_setTail` Inherited from `ElementSelector` (private): `_setMode` Inherited from `misc.state.ClassWithCollections`: `__getattribute__`, `__new__`, `__setattr__`, `__str__`, `reset` Inherited from `object`: `__delattr__`, `__format__`, `__hash__`, `__reduce__`, `__reduce_ex__`, `__sizeof__`, `__subclasshook__`

Class Variables | [hide private]

| nelements = `property(fget= lambda x: x.__nelements, fset= _set`...``
Inherited from `ElementSelector`: `mode`, `ndiscarded` Inherited from `misc.state.ClassWithCollections`: `_DEV__doc__`, `descr`

Properties | [hide private]

Inherited from `object`: `__class__`

Method Details | [hide private]

### __init__(self, nelements, **kwargs)
(Constructor)

source code

Cheap initialization.

Parameters:
  - `nelements` (int) - Number of elements to select/discard.
Overrides: object.__init__

### __repr__(self)
(Representation operator)

source code

String definition of the object of ClassWithCollections object

Parameters:
  - `fullname` - Either to include full name of the module
  - `prefixes` - What other prefixes to prepend to list of arguments
Overrides: object.__repr__
  (inherited documentation)

### _getNElements(self, seq)

source code

In derived classes has to return the number of elements to be processed given a sequence values forming the distribution.

Overrides: TailSelector._getNElements
  (inherited documentation)

Class Variable Details | [hide private]

### nelements

Value:

      property(fget= lambda x: x.__nelements, fset= _setNElements)