function NPAnalysis=NPanalyse(singleFRET, Np, tw)

javaclasspath({
   '/home/cocktail/meerbach/Netbeans_projects/Metamacs/dist/lib/colt.jar'...
   '/home/cocktail/meerbach/javawerkstatt/Metamacs/lib/concurrent.jar'...
   '/home/cocktail/meerbach/Netbeans_projects/Metamacs/build/classes/'...
   '/home/cocktail/luedge/code/mbtoolkit/torsten/FRETanalyser/netbeans_project/build/classes'...
   '/home/cocktail/luedge/code/mbtoolkit/torsten/FRETanalyser/NProbe/build/classes'...
   '/home/cocktail/luedge/NetBeansProjects/Metamacs/build/classes/biocomp/metamacs/hmm/newImplementation'...
  });
if isstruct(singleFRET)==1;
    NPAnalysis=singleFRET;
    for i=1:length(singleFRET)
     Np=2;
     tw=20;
          aFRET=Nprobe.probe(singleFRET(1,i).counts(:,2),singleFRET(1,i).counts(:,1),Np,tw);
    end
           NPmean=mean(aFRET);
           NPvar=var(aFRET);
        NPAnalysis(1,i).NPeff=aFRET;
        NPAnalysis(1,i).NPmean=NPmean;
        NPAnalysis(1,i).NPvar=NPvar;
        NPAnalysis(1,i).NPstd=sqrt(NPvar);
        NPAnalysis(1,i).NPvarest1=2*NPvar-NPmean-NPmean*NPmean;
        NPAnalysis(1,i).NPvarest1=2*NPvar-NPmean+NPmean*NPmean;

else
    NPAnalysis=Nprobe.probe(singleFRET(:,2),singleFRET(:,1),Np,tw);
end