%% Frequency-Response Data Model with Inherited Properties
% For this example, create a frequency-response data model with properties inherited from a transfer function model.
% Create a transfer function sys1 with the TimeUnit property set to 'minutes' and InputDelay property set to 3.

numerator1 = [2,0];
denominator1 = [1,8,0];
sys1 = tf(numerator1,denominator1,'TimeUnit','minutes','InputDelay',3)
propValues1 = {sys1.TimeUnit,sys1.InputDelay}

% Create an frd model with properties inherited from sys1.

rng(0)
response = randn(1,1,7)+1i*randn(1,1,7);
w = logspace(-2,2,7);
sys2 = frd(response,w,sys1)
propValues2 = {sys2.TimeUnit,sys2.InputDelay}

% Observe that the frd model sys2 has that same properties as sys1.
% Copyright 2021 The MathWorks, Inc.