function [S,E] = myunobsstruct(THIS,E)
% MYUNOBSSTRUCT  [Not a public function] Parse structure with unobservables estimation specs.
%
% Backend IRIS function.
% No help provided.

% -IRIS Toolbox.
% -Copyright (c) 2007-2012 Jaromir Benes.

%**************************************************************************

list = fieldnames(E).';
[assignpos,stdcorrpos,assignval,stdcorrval,type] = ...
   mynameposition(THIS,list); %#ok<ASGLU>

S.ulist = list(type == 1);
nu = length(S.ulist);
S.assignpos = assignpos(type == 1);
S.tseries = struct();
for i = 1 : nu
   name = S.ulist{i};
   S.tseries.(name) = E.(name);
end

E = rmfield(E,S.ulist);

end