library: libTree #include "TNtupleD.h"

# TNtupleD

class description - source file - inheritance tree (.pdf)

## class TNtupleD : public TTree

| Inheritance Chart:
`TObject`
| <- | `TNamed`
`TAttLine`
`TAttFill`
`TAttMarker`
| <- | `TTree`
| <- | `TNtupleD` |

        protected:

          virtual Int_t Fill()

        public:

                           TNtupleD()
                           TNtupleD(const char* name, const char* title, const char* varlist, Int_t bufsize = 32000)
                   virtual ~TNtupleD()
              virtual void Browse(TBrowser* b)
            static TClass* Class()
             virtual Int_t Fill(const Double_t* x)
             virtual Int_t Fill(Double_t x0, Double_t x1, Double_t x2 = 0, Double_t x3 = 0, Double_t x4 = 0, Double_t x5 = 0, Double_t x6 = 0, Double_t x7 = 0, Double_t x8 = 0, Double_t x9 = 0, Double_t x10 = 0, Double_t x11 = 0, Double_t x12 = 0, Double_t x13 = 0, Double_t x14 = 0)
                 Double_t* GetArgs() const
             virtual Int_t GetNvar() const
           virtual TClass* IsA() const
          virtual Long64_t ReadFile(const char* filename, const char* branchDescriptor = "")
              virtual void ResetBranchAddresses()
              virtual void ShowMembers(TMemberInspector& insp, char* parent)
              virtual void Streamer(TBuffer& b)
                      void StreamerNVirtual(TBuffer& b)

### Data Members

        protected:

              Int_t fNvar  Number of columns
          Double_t* fArgs  ! [fNvar] Array of variables

## Class Description

     TNtupleD

     A simple tree restricted to a list of double variables only.

     Each variable goes to a separate branch.

      A Ntuple is created via
         TNtupleD(name,title,varlist,bufsize)
      It is filled via:
         TNtupleD::Fill(*x)  or
         TNtupleD::Fill(v1,v2,v3.....)

TNtupleD(): TTree()

    *-*-*-*-*-*Default constructor for Ntuple*-*-*-*-*-*-*-*-*-*-*-*-*-*
    *-*        ==============================

TNtupleD(const char *name, const char *title, const char *varlist, Int_t bufsize) :TTree(name,title)

    *-*-*-*-*-*-*-*-*-*-*-*-*Create an Ntuple*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
    *-*                      ================
           The parameter varlist describes the list of the ntuple variables
           separated by a colon:
             example:  "x:y:z:energy"
           For each variable in the list a separate branch is created.

           Use TTree to create branches with variables of different data types.
    *-*

~TNtupleD()

    *-*-*-*-*-*Default destructor for an Ntuple*-*-*-*-*-*-*-*-*-*-*-*
    *-*        ================================

void ResetBranchAddresses()

     Reset the branch addresses to the internal fArgs array. Use this
     method when the addresses were changed via calls to SetBranchAddress().

void Browse(TBrowser *b)

Int_t Fill()

    *-*-*-*-*-*-*-*-*Fill a Ntuple with current values in fArgs*-*-*-*-*-*-*
    *-*              ==========================================
     Note that this function is protected.
     Currently called only by TChain::Merge

Int_t Fill(const Double_t *x)

    *-*-*-*-*-*-*-*-*Fill a Ntuple with an array of floats*-*-*-*-*-*-*-*-*-*
    *-*              =====================================

Int_t Fill(Double_t x0,Double_t x1,Double_t x2,Double_t x3,Double_t x4 ,Double_t x5,Double_t x6,Double_t x7,Double_t x8,Double_t x9 ,Double_t x10,Double_t x11,Double_t x12,Double_t x13,Double_t x14)

    *-*-*-*-*-*-*-*-*Fill a Ntuple: Each Ntuple item is an argument*-*-*-*-*-*-*
    *-*              ==============================================

Long64_t ReadFile(const char *filename, const char * /*branchDescriptor*/)

     read from filename as many columns as variables in the ntuple
     the function returns the number of rows found in the file
     The second argument "branchDescriptor" is currently not used.
     Lines in the input file starting with "#" are ignored.

void Streamer(TBuffer &b)

    *-*-*-*-*-*-*-*-*Stream a class object*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
    *-*              =========================================

### Inline Functions

                  Int_t GetNvar() const
              Double_t* GetArgs() const
                TClass* Class()
                TClass* IsA() const
                   void ShowMembers(TMemberInspector& insp, char* parent)
                   void StreamerNVirtual(TBuffer& b)

Author: Rene Brun 12/08/2001
Last update: root/tree:$Name: $:$Id: TNtupleD.cxx,v 1.5 2005/04/07 10:57:32 brun Exp $
Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *