+1
On Apr 29, 2014 12:03 PM, "Jai Ram Rideout" <notifications@github.com>
wrote:

> In biom/table.py:
>
> > +        ------
> > +        ValueError
> > +            If not all desired_ids are in source_ids
> > +        """
> > +        if desired_ids is not None:
> > +            # Get the index of the source ids to include
> > +            idx = np.in1d(source_ids, desired_ids)
> > +            # Retrieve only the ids that we are interested on
> > +            ids = source_ids[idx]
> > +            # Check that all desired ids have been found on source ids
> > +            if len(ids) != len(desired_ids):
> > +                raise ValueError("The following ids have not been found in "
> > +                                 "the biom table: %s" %
> > +                                 (set(desired_ids) - set(ids)))
> > +        else:
> > +            # Get all the observation ids
>
> Thinking about this more, if the user doesn't specify a subset, we should
> probably skip this method and the subsetting code altogether and directly
> pull the entire sparse matrix from file in one operation (like we were
> previously doing). This will be the most common interaction (at least in
> foreseeable future) and we'll want this to be as snappy as possible.
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/biocore/biom-format/pull/315/files#r12101074>
> .
>