# shrinkage::ScreeningDesign

Shrinkage for Rust · 0.3.0

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

```rust
pub trait ScreeningDesign
```

Optional normalized-column operations that avoid screened matrix work. 

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

## Associated types

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

### `Error`

```rust
type Error;
```

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

Backend failure type. 

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

## Methods

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

### `column_error_scales`

```rust
fn column_error_scales(
    &mut self,
    output: &mut [f64]
) -> Result<(), FitError<<Self as ScreeningDesign>::Error>>
```

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

Write absolute product scales accounting for normalization cancellation. 

A scale must bound the magnitudes entering a transposed product before cancellation, per unit Euclidean input norm. 

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

#### Errors

Reject incompatible dimensions or unrepresentable scales. 

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

### `column_norms`

```rust
fn column_norms(
    &mut self,
    output: &mut [f64]
) -> Result<(), FitError<<Self as ScreeningDesign>::Error>>
```

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

Write upper bounds for Euclidean norms of optimization-scale columns. 

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

#### Errors

Reject incompatible output dimensions or nonfinite arithmetic. 

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

### `forward_active`

```rust
fn forward_active(
    &mut self,
    input: &[f64],
    active: &[usize],
    output: &mut [f64]
) -> Result<(), FitError<<Self as ScreeningDesign>::Error>>
```

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

Multiply using only increasing, unique original indices in `active`. 

Input has the original coefficient dimension; output has one entry per row. 

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

#### Errors

Reject invalid dimensions or indices and preserve backend failures. 

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

### `transpose_active`

```rust
fn transpose_active(
    &mut self,
    input: &[f64],
    active: &[usize],
    output: &mut [f64]
) -> Result<(), FitError<<Self as ScreeningDesign>::Error>>
```

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

Write selected correlations into an original-length output, zeroing others. 

`active` contains increasing, unique original feature indices. 

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

#### Errors

Reject invalid dimensions or indices and preserve backend failures.
