Skip to content

Commit

Permalink
Merge pull request #1 from RomeshA/removed_chisq_outliers
Browse files Browse the repository at this point in the history
Removed chisq outlier removal from analysis
  • Loading branch information
RomeshA committed May 19, 2015
2 parents 01625f9 + 474a938 commit 94d4998
Show file tree
Hide file tree
Showing 6 changed files with 4 additions and 20 deletions.
4 changes: 1 addition & 3 deletions +mcmc/@feather/blobs.m
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,12 @@ function blobs(f)
figure

xyz = f.xyz;
chisq = f.chisq;
state_color = f.state_colors;
cdata = braintrack_utils.state_cdata;
contaminated = braintrack_utils.chisq_outliers(chisq);


for j = 1:size(cdata,1)
pts = state_color == j & ~contaminated(:);
pts = state_color == j;
if any(pts)
h = utils.alphavol_wrapper(xyz(pts,:),Inf);

Expand Down
6 changes: 1 addition & 5 deletions +mcmc/@feather/clouds.m
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,6 @@ function clouds(f)
figure

xyz = f.xyz;

chisq = f.chisq;
contaminated = braintrack_utils.chisq_outliers(chisq);

state_color = f.state_colors;
cdata = braintrack_utils.state_cdata;

Expand All @@ -17,7 +13,7 @@ function clouds(f)
gridres = 0.025;

for j = 1:size(cdata,1)
pts = state_color == j & ~contaminated(:);
pts = state_color == j;
if any(pts)
[Vcount] = utils.simple_bin3d(xyz(pts,:),xyzlim,gridres);
vol = mcmc.viewer.vol3d_alpha_fast(gca,xyzlim,j*+(Vcount>0),Vcount);
Expand Down
8 changes: 2 additions & 6 deletions +mcmc/@feather/cones.m
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@ function cones(f)
%if ~isnumeric(varargin{1})
%f = varargin{1};
xyz = f.xyz;
chisq = f.chisq;
contaminated = braintrack_utils.chisq_outliers(chisq);
fitted = isfinite(chisq) & ~contaminated;
fitted = isfinite(chisq);
valid = [fitted(2:end)==1 & fitted(1:end-1)==1]; % This says
% else
% xyz = varargin{1};
Expand Down Expand Up @@ -97,9 +95,7 @@ function cones(f)
f = mcmc.feather.import(sprintf('postmaster/control_apnea_art_%d_postmaster',j));

xyz = f.xyz;
chisq = f.chisq;
contaminated = braintrack_utils.chisq_outliers(chisq);
fitted = isfinite(chisq) & ~contaminated;
fitted = isfinite(chisq);
valid = [fitted(2:end)==1 & fitted(1:end-1)==1]; % This says

xyzdiff = [xyzdiff; diff(xyz)];
Expand Down
2 changes: 0 additions & 2 deletions +mcmc/@feather/plot_track.m
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,4 @@
xyz = f.xyz;
end

contaminated = braintrack_utils.chisq_outliers(f.chisq);
xyz(contaminated,:) = NaN;
h_out = f.plot_statecolored(xyz(:,1),xyz(:,2),xyz(:,3));
2 changes: 0 additions & 2 deletions +mcmc/@feather/timecourse.m
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,6 @@ function plot_timecourse(f,nocolor,smoothed)

xv = 1:f.latest;

contaminated = braintrack_utils.chisq_outliers(f.chisq);
yv(contaminated,:) = NaN;

for j = 1:length(param_names)
ax(end+1) = subplot(n_rows,n_cols,1+a_idx(ceil(j/2),mod(j-1,2)));
Expand Down
2 changes: 0 additions & 2 deletions +mcmc/@viewer/viewer.m
Original file line number Diff line number Diff line change
Expand Up @@ -364,8 +364,6 @@ function set_spec_electrode(self,idx)

function prep_animation(self)
chisq = self.feather.chisq;
contaminated = braintrack_utils.chisq_outliers(chisq);
chisq(contaminated) = NaN;

fixed_idx = arrayfun(@(x) x.skip_fit(1),self.feather.fit_data) == 3;
time_idx = self.feather.time;
Expand Down

0 comments on commit 94d4998

Please sign in to comment.