ソースを参照

old updates to the fir filter shape extraction function

Fernando Pablo Lopez-Lezcano 9 年 前
親
コミット
0b92fe5b4f
1 ファイル変更、4 行追加、9 行削除
  1. 4 9
      calibration/src/sphear_fir_extract.m

+ 4 - 9
calibration/src/sphear_fir_extract.m

@@ -23,13 +23,13 @@
 %%  You should have received a copy of the GNU General Public License
 %%  along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-function [W X Y Z] = sphear_fir_extract(B, all, onaxis);
-
+function [W X Y Z] = sphear_fir_extract(B, all, cardinal);
+  %% select which measurements to average
   if (all == 1)
     m = (1:16);
   else
-    if (onaxis == 1)
-      m = [1,5,9,13];
+    if (cardinal == 1)
+      m = [1, 5, 9, 13];
     else
       m = [3, 7, 11, 15];
     end
@@ -37,13 +37,8 @@ function [W X Y Z] = sphear_fir_extract(B, all, onaxis);
   
   %% extract average response shape for W
   W = 1.0 ./ reshape(mean(B(m,1,:)), size(B(:,:,:))(3), 1);
-
   %% extract average response shape for XYZ
-  % XYZ = 1.0 ./ reshape(mean(mean(B(m, [2, 3, 4], :))), size(B(:,:,:))(3), 1);
-
   X = 1.0 ./ reshape(mean(B(m,2,:)), size(B(:,:,:))(3), 1);
   Y = 1.0 ./ reshape(mean(B(m,3,:)), size(B(:,:,:))(3), 1);
   Z = 1.0 ./ reshape(mean(B(m,4,:)), size(B(:,:,:))(3), 1);
-
 end
-