making figure from matrix?
3 views (last 30 days)
Show older comments
hello,
i am trying to plot three different figures for three subjects. E.g. I want to plot one graph looking at the caudate for subject 1, then one caudate graph for subject 2 and have there be seperate graphs spit out. I tried below, but it isn't working:
subj = {'subj01' 'subj02' 'subj03'}
for k = 1:3
tac(:,k) = load(fullfile(D,subj{k},'tacs','km.hb.tac.dat.txt'));
tac_caudate(:,k) = load(fullfile(D,subj{k},'tacs','caudate.txt'));
tac_putamen(:,k) = load(fullfile(D,subj{k},'tacs','putamen.txt'));
tac_pallidum(:,k) = load(fullfile(D,subj{k'},'tacs','pallidum.txt'));
tac_ref(:,k) = load(fullfile(D,subj{k},'tacs','km.ref.tac.dat.txt'))
%% detrend ventricle and cortex
d_tac_ts_2 = (tac) %detrended time series of pet
d_tac_ref_ts_2 = (tac_ref) %reference
d_tac_caudate_ts_2 = (tac_caudate)
d_tac_putamen_ts_2 = (tac_putamen)
d_tac_pallidum_ts_2 = (tac_pallidum)
%% plotting in graphs
for subj{k}
figure(k)
plot(t_pet, d_tac_ts_2(:,k))
plot(t_pet, d_tac_ref_2(:,k))
end
end
Also, I want to have a figure where I each each subject's caudate, putamen, pallidum, etc. How would I go about doing this??
Thanks for the help!
1 Comment
Jan
on 18 Feb 2021
Please explain "it isn't working" with any details.
"have a figure where I each each subject's caudate, putamen, pallidum, etc." - this is not clear to me yet.
Answers (0)
See Also
Categories
Find more on MRI in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!