Index: trunk/MagicSoft/Mars/mhist/MHSigmaTheta.cc
===================================================================
--- trunk/MagicSoft/Mars/mhist/MHSigmaTheta.cc	(revision 1956)
+++ trunk/MagicSoft/Mars/mhist/MHSigmaTheta.cc	(revision 1961)
@@ -27,5 +27,7 @@
 //  MHSigmaTheta (extension of Robert's MHSigmabarTheta)                    //
 //                                                                          //
-//  calculates - the 2D-histogram   sigmabar vs. Theta, and                 //
+//  calculates - the 1D-histogram   ID of blind pixels
+//             - the 1D-histogram   no.of pixels in MCerPhotEvt, and        //
+//             - the 2D-histogram   sigmabar vs. Theta, and                 //
 //             - the 3D-histogram   sigma, pixel no., Theta                 //
 //             - the 3D-histogram   (sigma^2-sigmabar^2), pixel no., Theta  //
@@ -68,4 +70,16 @@
     fName  = name  ? name  : "MHSigmaTheta";
     fTitle = title ? title : "2D histogram sigmabar vs. Theta";
+
+    fNpix.SetDirectory(NULL);
+    fNpix.SetName("1D-Npix");
+    fNpix.SetTitle("1D : no.of used pixels in MCerPhotEvt");
+    fNpix.SetXTitle("no. of used pixels in MCerPhotEvt");
+    fNpix.SetYTitle("Counts");
+
+    fBlindId.SetDirectory(NULL);
+    fBlindId.SetName("1D-BlindId");
+    fBlindId.SetTitle("1D : Id of blind pixel");
+    fBlindId.SetXTitle("Id of blind pixel");
+    fBlindId.SetYTitle("Counts");
 
     fSigmaTheta.SetDirectory(NULL);
@@ -164,6 +178,8 @@
 
    MBinning binspix("BinningPixel");
-   binspix.SetEdges(npix, -0.5, -0.5+npix );
-
+   binspix.SetEdges(npix+1, -0.5, 0.5+npix );
+
+   SetBinning(&fNpix,    &binspix);
+   SetBinning(&fBlindId, &binspix);
    SetBinning(&fSigmaPixTheta, binstheta, &binspix, binssigma);
    SetBinning(&fDiffPixTheta,  binstheta, &binspix, binsdiff);
@@ -183,17 +199,26 @@
     Double_t mySig = fSigmabar->Calc(*fCam, *fPed, *fEvt);
 
+    //*fLog << "MHSigmaTheta::Fill; theta, mySig = " << theta << ",  "
+    //      << mySig << endl;
+
     fSigmaTheta.Fill(theta, mySig);
 
     const UInt_t npix = fEvt->GetNumPixels();
+
+    Int_t npixused=0;
     for (UInt_t i=0; i<npix; i++)
     {
       MCerPhotPix cerpix = fEvt->operator[](i);
       if (!cerpix.IsPixelUsed())
+      {
+        fBlindId.Fill( cerpix.GetPixId() );        
         continue;
-
-      /*
+      }
+      npixused++;
+
+      /*      
       if (cerpix.GetNumPhotons() == 0)
         continue;
-        */
+      */       
 
       const Int_t id = cerpix.GetPixId();
@@ -203,9 +228,15 @@
       const Double_t area  = fCam->GetPixRatio(id);
 
+
       fSigmaPixTheta.Fill(theta, (Double_t)id, sigma);
 
       const Double_t diff = sigma*sigma/area - mySig*mySig;
       fDiffPixTheta.Fill(theta, (Double_t)id, diff);
+
+      //*fLog << "theta, id, sigma, diff, area  = " << theta << ",  " << id 
+      //      << ",  "
+      //      << sigma << ",  " << diff << ",  " << area << endl;
     }
+    fNpix.Fill(npixused);
 
     return kTRUE;
@@ -277,6 +308,9 @@
     l->SetBit(kCanDelete);;
 
+    //c.cd(8);
+    //((TH2*)&fDiffPixTheta)->DrawCopy(opt);
+
     c.cd(8);
-    ((TH2*)&fDiffPixTheta)->DrawCopy(opt);
+    ((TH1*)&fBlindId)->DrawCopy(opt);
 
 
@@ -306,6 +340,9 @@
     k->SetBit(kCanDelete);;
 
+    //c.cd(9);
+    //((TH2*)&fSigmaPixTheta)->DrawCopy(opt);
+
     c.cd(9);
-    ((TH2*)&fSigmaPixTheta)->DrawCopy(opt);
+    ((TH1*)&fNpix)->DrawCopy(opt);
 
     //--------------------------------------------------------------------
Index: trunk/MagicSoft/Mars/mhist/MHSigmaTheta.h
===================================================================
--- trunk/MagicSoft/Mars/mhist/MHSigmaTheta.h	(revision 1956)
+++ trunk/MagicSoft/Mars/mhist/MHSigmaTheta.h	(revision 1961)
@@ -32,5 +32,8 @@
     MMcEvt         *fMcEvt;      //!
  
-    TH2D fSigmaTheta;    // 2D-distribution sigmabar versus Theta; sigmabar is the average pedestasl sigma in an event
+    TH1D fNpix;          // 1D-distribution no.of pixels in MCerPhotEvt; 
+    TH1D fBlindId;       // 1D-distribution Id of blind pixel; 
+    TH2D fSigmaTheta;    // 2D-distribution sigmabar versus Theta; 
+                         // sigmabar is the average pedestasl sigma in an event
     TH3D fSigmaPixTheta; // 3D-distr.:Theta, pixel, pedestal sigma
     TH3D fDiffPixTheta;  // 3D-distr.:Theta, pixel, sigma^2-sigmabar^2
