deernet.m
Extracts a distance distribution from primary DEER data using a supplied ensemble of trained neural networks. The experimental DEER trace is first reshaped to match the data expected by the neural networks. This involves normalising the trace to decay from a maximum of 1 to 0, between t=0 and t=tmax; and then resampling so that the DEER trace is discretised to a grid matching the dimensions defined by the network input layer (see: deer_resample.m).
The DEER trace is then presented to each network in the supplied ensemble to obtain the individual responses. The ensemble output is found as the mean response for each point in the distribution; and 95% confidence bounds are computed using the standard deviation of the individual responses. A detailed description of the use of the ensemble responses as an uncertainty estimate is provided in Section 2.6 of our paper (https://dx.doi.org/10.1126/sciadv.aat5218).
Contents
Syntax
deernet(deer_trace,time_axis,net_dir)
[dist_axis,outcomes]=deernet(deer_trace,time_axis,net_dir)
Arguments
deer_trace - the real experimental DEER trace, as a column
vector.
time_axis - experimental time axis, a column vector in
microseconds, must start at zero and have
a uniform time step.
net_dir - directory containing a curated network ensemble,
as multiple *.mat files and the supporting files.
(see: Netset folder structure)
Outputs
If no output is requested then the function produces a plot as in the example below. The function may also be called with the following output arguments specified:
dist_axis - the distance axis, as a column vector in
Angstroms.
outcomes - output distance distributions, a horizontal
array of column vectors. Where each column is the
response of a single network from the ensemble.
If the outputs are requested then in-built plotting is suppressed.
Examples
The example below shows the use of DEERNet to extract a distance distribution for Sample V (as described in our paper on the subject). This example may be run from within examples/deernet/. First the network ensemble optimized for processing any width of distribution is selected:
% Select the network ensemble to use in analysis
netset_location='net_set_any_peaks';
The experimental data is loaded, and the time axis is converted to microseconds:
% Load experimental data
expt_data=load('sample_set_paper/sample_V_DEERNet_input.dat','-ASCII');
deer_trace=expt_data(:,2);
time_axis=expt_data(:,1)*1e-6;
The data is then presented to the selected network ensemble:
% Run deernet analysis
deernet(deer_trace,time_axis,netset_location);
With no output arguments requested in the call to DEERNet, the following plot is produced.
Further examples are available under examples/deernet/
- example_set_paper.m - The six examples used in the paper on DEERNet.
- example_set_deeran.m - Selection of the examples included with the DeerAnalysis package.
- example_set_exchange.m - Examples of DEER traces in the presence of significant exchange interaction. Data provided by Sabine Richert et al., from the supplementary information of their paper available here.
Notes
Data pre-processing
The provided neural networks are trained using libraries of simulated DEER traces uniformly scaled to decay from the maximum at time zero. This means that experimental data may need to be shifted accordingly before presenting to the network, demonstrated in the figure above.
This is the only pre-processing required by DEERNet; scaling and resampling of the data are performed internally and the networks have been trained to compensate for background contributions and instrumental noise.
(This processing is performed within the elexsys2deernet.m function for standard Bruker datasets)
See also
Functions used
deer_resample.m, netset_params.m, process_using.m
Other related functions
deer_lib_gen.m, netset_curate.m, train_one_net.m
Version 2.2, authors: Ilya Kuprov, Steve Worswick, Gunnar Jeschke

