# shrinkage::RowSubset

Shrinkage for Rust · 0.3.0

[Source](<https://github.com/jolars/shrinkage/blob/eeafe449edce19d3c552a03060f681ae3891af74/src/cross_validation/rows.rs>)

```rust
pub trait RowSubset: RawColumns<f64> + ColumnStats<f64>
```

Select raw observations before fitting training-fold preprocessing. 

Selected designs retain column order and use the same backend error type. Implementations must neither estimate nor apply normalization. The built-in dense and CSC integrations copy only selected entries into owned storage, then delegate statistics and products to LazyMatrix's backend integrations. Custom backends can supply their own raw selection implementation. 

<a id="associated-types"></a>

## Associated types

<a id="associated-type-Subset"></a>

### `Subset`

```rust
type Subset: RawColumns<f64> + ColumnStats<f64, Error = <Self as >::Error>;
```

[Source](<https://github.com/jolars/shrinkage/blob/eeafe449edce19d3c552a03060f681ae3891af74/src/cross_validation/rows.rs>)

Selected raw design used by the fold's ordinary path solver. 

<a id="methods"></a>

## Methods

<a id="method-select_rows"></a>

### `select_rows`

```rust
fn select_rows(
    &self,
    rows: &[usize]
) -> Result<<Self as RowSubset>::Subset, FitError<<Self as >::Error>>
```

[Source](<https://github.com/jolars/shrinkage/blob/eeafe449edce19d3c552a03060f681ae3891af74/src/cross_validation/rows.rs>)

Select strictly increasing original row indices without changing columns. 

<a id="method-select_rows-documentation-errors"></a>

#### Errors

Reject repeated, unsorted, or out-of-bounds indices and backend failures.
