function fetch_xform2

% created by Mark Smith 1/15/08
% code used with Shim Calculation GUI 
% This function created to accomodate current center Re-Alignment.

xform2=0;
[s1 s2]=uigetfile('*.mat','Select Transformation 2 .mat file');
set(findobj('tag','tx202'),'string',s1);
temp = struct2cell(open(strcat(s2,s1)));
xform2=temp{1};

% Apply transformation.
data2 = evalin('base','data2');
data2(:,4)=1;       % for transformation algorithm.

rdata2=zeros(length(data2),4);

for fc1=1:length(data2)
    rdata2(fc1,:)=(xform2*data2(fc1,:)')';
end

%assignin('base','xform2',xform2);
assignin('base','rdata2',rdata2);

