<commit_before>/// \file draw.cxx
/// \ingroup Tutorials
/// \author <NAME> <<EMAIL>>
/// \date 2015-03-22
/// \warning This is part of the ROOT 7 prototype! It will change without notice. It might trigger earthquakes. Feedback is welcome!

/*************************************************************************
 * Copyright (C) 1995-2015, <NAME> and <NAME>.               *
 * All rights reserved.                                                  *
 *                                                                       *
 * For the licensing terms see $ROOTSYS/LICENSE.                         *
 * For the list of contributors see $ROOTSYS/README/CREDITS.             *
 *************************************************************************/

#include "Rtypes.h"

R__LOAD_LIBRARY(libGpad)

#include "ROOT/THist.h"
#include "ROOT/TCanvas.h"
#include "ROOT/TDirectory.h"
#include <iostream>

void example() {
  using namespace ROOT;

  auto pHist = MakeCoop<THist<2, double>>(TAxisConfig{100, 0., 1.},
                                          TAxisConfig{{0., 1., 2., 3.,10.}});

  pHist->Fill({0.01, 1.02});
  experimental::TDirectory::Heap().Add("hist", pHist);

  auto canvas = experimental::TCanvas::Create("MyCanvas");
  canvas->Draw(pHist);
}

void draw() {
  example();

  // And the event loop (?) will call
  for (auto&& canv: experimental::TCanvas::GetCanvases())
    canv->Paint();
}<commit_msg>Update namespace Capitalization.<commit_after>/// \file draw.cxx
/// \ingroup Tutorials
/// \author <NAME> <<EMAIL>>
/// \date 2015-03-22
/// \warning This is part of the ROOT 7 prototype! It will change without notice. It might trigger earthquakes. Feedback is welcome!

/*************************************************************************
 * Copyright (C) 1995-2015, <NAME> and <NAME>.               *
 * All rights reserved.                                                  *
 *                                                                       *
 * For the licensing terms see $ROOTSYS/LICENSE.                         *
 * For the list of contributors see $ROOTSYS/README/CREDITS.             *
 *************************************************************************/

#include "Rtypes.h"

R__LOAD_LIBRARY(libGpad)

#include "ROOT/THist.h"
#include "ROOT/TCanvas.h"
#include "ROOT/TDirectory.h"
#include <iostream>

void example() {
  using namespace ROOT;

  Experimental::TAxisConfig xaxis("x", 100, 0., 1.);
  Experimental::TAxisConfig yaxis("y", {0., 1., 2., 3.,10.});
  auto pHist = std::make_shared<Experimental::TH2D>(xaxis, yaxis);

  pHist->Fill({0.01, 1.02});
  Experimental::TDirectory::Heap().Add("hist", pHist);

  auto canvas = Experimental::TCanvas::Create("MyCanvas");
  canvas->Draw(pHist);
}

void draw() {
  example();

  // And the event loop (?) will call
  for (auto&& canv: Experimental::TCanvas::GetCanvases())
    canv->Paint();
}
{'fraction_non_alphanumeric': 0.23659633344863368, 'fraction_numerical': 0.024213075060532687, 'mean_word_length': 2.48014440433213, 'pattern_counts': {'":': 0, '<': 18, '<?xml version=': 0, '>': 24, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 12, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3672181', 'n_tokens_mistral': 868, 'n_tokens_neox': 779, 'n_words': 209}