function [theWaves,Vmaxs,imaxs,badWaves,baseMean,baseRMS,lightsource,rawevstats,scopescale,theTimescale,triglevel] = rip(loc)

theWaves=[];
badWaves=[];
baseMean=[];
baseRMS=[];
lightsource=[];
rawevstats=[];
scopescale=[];
theTimescale=[];
triglevel=[];

    [pname,fname,~,~,~,~,~,~,~,~,~] = L2Params(2);

    TTn= [pname fname];
    load(TTn);

[~,p,~] = size(theWaves);

xx = ones(p,1);
xx(loc,1) = 0;

theWaves = theWaves(:,logical(xx),:);
baseRMS = baseRMS(:,logical(xx));
baseMean = baseMean(:,logical(xx));
[Vmaxs,imaxs] = getMaxs(theWaves);

end