msmbuilder.featurizer.RMSDFeaturizer

class msmbuilder.featurizer.RMSDFeaturizer(trj0, atom_indices=None)

Featurizer based on RMSD to a series of reference frames.

Parameters:

trj0 : mdtraj.Trajectory

Reference trajectory. trj0.n_frames gives the number of features in this Featurizer.

atom_indices : np.ndarray, default=None

Which atom indices to use during RMSD calculation. If None, MDTraj should default to all atoms.

Methods

featurize(traj)
fit(traj_list[, y])
fit_transform(X[, y]) Fit to data, then transform it.
get_params([deep]) Get parameters for this estimator.
partial_transform(traj) Featurize an MD trajectory into a vector space by calculating the RMSD to each frame in a reference trajectory.
save(filename)
set_params(**params) Set the parameters of this estimator.
summarize() Return some diagnostic summary statistics about this Markov model
transform(traj_list[, y]) Featurize a several trajectories.
partial_transform(traj)

Featurize an MD trajectory into a vector space by calculating the RMSD to each frame in a reference trajectory.

Parameters:

traj : mdtraj.Trajectory

A molecular dynamics trajectory to featurize.

Returns:

features : np.ndarray, dtype=float, shape=(n_samples, n_features)

A featurized trajectory is a 2D array of shape (length_of_trajectory x n_features) where each features[i] vector is computed by applying the featurization function to the `i`th snapshot of the input trajectory.

See also

transform
simultaneously featurize a collection of MD trajectories
fit_transform(X, y=None, **fit_params)

Fit to data, then transform it.

Fits transformer to X and y with optional parameters fit_params and returns a transformed version of X.

Parameters:

X : numpy array of shape [n_samples, n_features]

Training set.

y : numpy array of shape [n_samples]

Target values.

Returns:

X_new : numpy array of shape [n_samples, n_features_new]

Transformed array.

get_params(deep=True)

Get parameters for this estimator.

Parameters:

deep: boolean, optional

If True, will return the parameters for this estimator and contained subobjects that are estimators.

Returns:

params : mapping of string to any

Parameter names mapped to their values.

set_params(**params)

Set the parameters of this estimator.

The method works on simple estimators as well as on nested objects (such as pipelines). The former have parameters of the form <component>__<parameter> so that it’s possible to update each component of a nested object.

Returns:self
summarize()

Return some diagnostic summary statistics about this Markov model

transform(traj_list, y=None)

Featurize a several trajectories.

Parameters:

traj_list : list(mdtraj.Trajectory)

Trajectories to be featurized.

Returns:

features : list(np.ndarray), length = len(traj_list)

The featurized trajectories. features[i] is the featurized version of traj_list[i] and has shape (n_samples_i, n_features)

Versions