|
79 | 79 | % is in matlab or if my data can be one, or what a linear time-invariant |
80 | 80 | % system is or why a Bode plot is useful |
81 | 81 | %% |
| 82 | +figure(); |
82 | 83 | eachFreq = [0 10 30 100 200 500 1000]; |
83 | 84 | sf = 10000; %Hz |
84 | 85 | allPSD = []; |
85 | 86 | allF = []; |
86 | 87 | allSize = []; |
87 | 88 |
|
88 | | -whichPeaks = sinePeaks; |
| 89 | +whichPeaks = sinePeaksPD; |
89 | 90 | % ally = []; %for plotting fft magnitude and phase |
90 | 91 | % allf_fft = []; |
91 | 92 |
|
|
147 | 148 | set(gca,'children',flipud(chH)); |
148 | 149 | plotfixer; |
149 | 150 |
|
| 151 | +% meansByFreqPD = meansByFreq; |
| 152 | +% meansByFreqI = meansByFreq; |
| 153 | + |
| 154 | +%% Plot stacked power spectra |
| 155 | +figure(); |
| 156 | +yyh = cell(0); |
| 157 | + |
| 158 | +for i = 1:size(meansByFreq,2) |
| 159 | + axh(i) = subtightplot(size(meansByFreq,2),1,i,0.02,0.05,0.1); |
| 160 | + yyh{i} = plotyy(meanF,meansByFreqI(:,i),meanF,meansByFreqPD(:,i)); |
| 161 | + set(yyh{i}, 'YScale', 'log', 'XScale', 'log','box','off'); |
| 162 | + set(yyh{i}(1),'YLim',[1e-30 1e-20]) |
| 163 | + set(yyh{i}(2),'YLim',[1e-10 1e0]) |
| 164 | +end |
| 165 | + |
| 166 | +for i = 1:size(meansByFreq,2)-1 |
| 167 | + set(yyh{i},'XTickLabel',[]); |
| 168 | +end |
| 169 | + |
| 170 | + |
150 | 171 | %% Plot steady state sine comparison |
151 | 172 |
|
152 | 173 | whichPeaks = sinePeaksNorm; |
|
0 commit comments