# Newbie

**URL:** https://root-forum.cern.ch/c/newbie/26.md?page=101

[Latest](https://root-forum.cern.ch/latest.md) · [Categories](https://root-forum.cern.ch/categories.md) · [Tags](https://root-forum.cern.ch/tags.md)

**Page:** 102

---

## [Entry range in TNtupleD](https://root-forum.cern.ch/t/entry-range-in-tntupled/38366)

<div class="topic-metadata">

**Author:** [@clay](https://root-forum.cern.ch/u/clay)\
**Replies:** 4\
**Last updated:** [March 12, 2020, 8:02am UTC](https://root-forum.cern.ch/t/entry-range-in-tntupled/38366 "2020-03-12T08:02:34Z")

</div>

Please read tips for efficient and successful posting and posting code ROOT Version: V7 Platform: Ubuntu 18.04 \_Compiler:gcc & g++ How to print the entry range (first entry, last entry) for each of the clusters of …

---

## [Setting axes on TGraph2D (cont 4z)](https://root-forum.cern.ch/t/setting-axes-on-tgraph2d-cont-4z/38284)

<div class="topic-metadata">

**Author:** [@rms](https://root-forum.cern.ch/u/rms)\
**Replies:** 6\
**Last updated:** [March 12, 2020, 3:59am UTC](https://root-forum.cern.ch/t/setting-axes-on-tgraph2d-cont-4z/38284 "2020-03-12T03:59:58Z")

</div>

Hi, I am having trouble setting my axes on a TGraph2D. On the forums they mentioned that I could use SetHistogram(), but I don’t know how to use that. All this code is in PyROOT, but the only difference is that pointers …

---

## [RootV7 RNtuple examples](https://root-forum.cern.ch/t/rootv7-rntuple-examples/38363)

<div class="topic-metadata">

**Author:** [@clay](https://root-forum.cern.ch/u/clay)\
**Replies:** 3\
**Last updated:** [March 11, 2020, 2:06pm UTC](https://root-forum.cern.ch/t/rootv7-rntuple-examples/38363 "2020-03-11T14:06:11Z")

</div>

Please read tips for efficient and successful posting and posting code ROOT Version: Not Provided Platform: Not Provided Compiler: Not Provided When I am running a macro from Rootv7 tutorials first time it works pr…

---

## [Displaying LEAF to new Canvas, Dividing Canvas](https://root-forum.cern.ch/t/displaying-leaf-to-new-canvas-dividing-canvas/38353)

<div class="topic-metadata">

**Author:** [@SpookyCat23](https://root-forum.cern.ch/u/SpookyCat23)\
**Replies:** 1\
**Last updated:** [March 11, 2020, 9:16am UTC](https://root-forum.cern.ch/t/displaying-leaf-to-new-canvas-dividing-canvas/38353 "2020-03-11T09:16:55Z")

</div>

Hi all, I am trying to get a premade histogram, that is saved as a branch, to display onto a new Canvas. I am looking for the command that will do this. Something like: Canvas1-\>print(“branchname”) I am also having tr…

---

## [No matching constructor for initialization of 'TTreeReaderValue\<Int\_t\>'](https://root-forum.cern.ch/t/no-matching-constructor-for-initialization-of-ttreereadervalue-int-t/38341)

<div class="topic-metadata">

**Author:** [@ets9](https://root-forum.cern.ch/u/ets9)\
**Replies:** 16\
**Last updated:** [March 10, 2020, 7:56pm UTC](https://root-forum.cern.ch/t/no-matching-constructor-for-initialization-of-ttreereadervalue-int-t/38341 "2020-03-10T19:56:56Z")

</div>

Hello folks, I’m working for the first time with ntuples and during the common steps taken in order to analyze the file, namely: root \[0\] TFile \*f = TFile::Open("myNTuple.root") (TFile \*) 0x561e2edc0260 root \[1\] TTree \*…

---

## [Matrix inversion failed?](https://root-forum.cern.ch/t/matrix-inversion-failed/38206)

<div class="topic-metadata">

**Author:** [@Ferd](https://root-forum.cern.ch/u/Ferd)\
**Replies:** 4\
**Last updated:** [March 10, 2020, 12:14pm UTC](https://root-forum.cern.ch/t/matrix-inversion-failed/38206 "2020-03-10T12:14:21Z")

</div>

I used method explained in example https://root.cern.ch/root/html/tutorials/matrix/invertMatrix.C.html to inverse a 36\*36 matrix with small numbers. It fails for the method Invert() and InvertFast(), saying the matrix …

---

## [Add one more variable in ROOT 7 build command](https://root-forum.cern.ch/t/add-one-more-variable-in-root-7-build-command/38229)

<div class="topic-metadata">

**Author:** [@rudradesai200](https://root-forum.cern.ch/u/rudradesai200)\
**Replies:** 2\
**Last updated:** [March 10, 2020, 9:38am UTC](https://root-forum.cern.ch/t/add-one-more-variable-in-root-7-build-command/38229 "2020-03-10T09:38:59Z")

</div>

https://root.cern/root-7 - - on this page a command is given to help build root 7, it should be slightly modified as, it is not building root 7 experimental files properly. I found this command working cmake -DCMAKE\_CX…

---

## [Opening a .root tree file](https://root-forum.cern.ch/t/opening-a-root-tree-file/38335)

<div class="topic-metadata">

**Author:** [@unimelb](https://root-forum.cern.ch/u/unimelb)\
**Replies:** 1\
**Last updated:** [March 10, 2020, 8:26am UTC](https://root-forum.cern.ch/t/opening-a-root-tree-file/38335 "2020-03-10T08:26:38Z")

</div>

Hi, I am sent a .root data file by a colleague and I know from speaking to him that this file is a tree. I am not sure how to open the file. When trying to open it through my IDA (PyCharm) it just opens as one single lar…

---

## [libPyROOT\_rdict.pcm files not installing](https://root-forum.cern.ch/t/libpyroot-rdict-pcm-files-not-installing/38303)

<div class="topic-metadata">

**Author:** [@evonreis](https://root-forum.cern.ch/u/evonreis)\
**Replies:** 2\
**Last updated:** [March 9, 2020, 9:32am UTC](https://root-forum.cern.ch/t/libpyroot-rdict-pcm-files-not-installing/38303 "2020-03-09T09:32:46Z")

</div>

ROOT Version: 6.20.0 Platform: Debian 10 amd64 Compiler: GCC Debian 8.3.0-6 When building and installing version from source, libPyROOT\_rdict.pcm is not installed, but when I import ROOT in Python 3.7, it complains th…

---

## [Possible memory leak writing TTrees?](https://root-forum.cern.ch/t/possible-memory-leak-writing-ttrees/38227)

<div class="topic-metadata">

**Author:** [@jwruss](https://root-forum.cern.ch/u/jwruss)\
**Replies:** 8\
**Last updated:** [March 8, 2020, 8:47am UTC](https://root-forum.cern.ch/t/possible-memory-leak-writing-ttrees/38227 "2020-03-08T08:47:19Z")

</div>

makeKLCoeffsOriginal.C (15.3 KB) I run the attached macro using as input files containing TTrees of variable length. As the length of the trees become larger the more memory they use. If they get too large, it appears o…

---

## [Ftimedisplay and SetTimeDisplay()](https://root-forum.cern.ch/t/ftimedisplay-and-settimedisplay/38299)

<div class="topic-metadata">

**Author:** [@kevinlinxc](https://root-forum.cern.ch/u/kevinlinxc)\
**Replies:** 1\
**Last updated:** [March 6, 2020, 7:17pm UTC](https://root-forum.cern.ch/t/ftimedisplay-and-settimedisplay/38299 "2020-03-06T19:17:55Z")

</div>

Can anyone explain how these work? Specifically, what does SetTimeDisplay(1) do to a graph and what are the preconditions for that to work? Does the graph already need to have an x axis? ROOT Version: 6.18/04 Platform…

---

## [Memory/other limiting factor](https://root-forum.cern.ch/t/memory-other-limiting-factor/38254)

<div class="topic-metadata">

**Author:** [@kevinlinxc](https://root-forum.cern.ch/u/kevinlinxc)\
**Replies:** 10\
**Last updated:** [March 6, 2020, 3:50pm UTC](https://root-forum.cern.ch/t/memory-other-limiting-factor/38254 "2020-03-06T15:50:28Z")

</div>

My program finds 72 .root files and is supposed to operate on all of them. However, it suddenly stops, usually around the 21st file. I thought maybe there was a limit to how much could be printed to the terminal, but aft…

---

## [Macro in another macro](https://root-forum.cern.ch/t/macro-in-another-macro/38279)

<div class="topic-metadata">

**Author:** [@kevinlinxc](https://root-forum.cern.ch/u/kevinlinxc)\
**Replies:** 4\
**Last updated:** [March 6, 2020, 3:29pm UTC](https://root-forum.cern.ch/t/macro-in-another-macro/38279 "2020-03-06T15:29:27Z")

</div>

Is there a modern way to run a macro from another macro? The search results that come up for this are emails from 2001 and 2003, so I’m hoping there’s a better way now. The problem with gROOT-\>ProcessLine(“macro”); is …

---

## [Graph with strings as x axis](https://root-forum.cern.ch/t/graph-with-strings-as-x-axis/38274)

<div class="topic-metadata">

**Author:** [@kevinlinxc](https://root-forum.cern.ch/u/kevinlinxc)\
**Replies:** 25\
**Last updated:** [March 6, 2020, 3:02pm UTC](https://root-forum.cern.ch/t/graph-with-strings-as-x-axis/38274 "2020-03-06T15:02:53Z")

</div>

To start, I know it’s not possible to have alphanumerical axis for graphs. I’ve based my code off the previous posts asking this but they aren’t that clear. Here’s the abstract problem: I have a vector of strings and a…

---

## [Can't open TBrowser in windows powershell](https://root-forum.cern.ch/t/cant-open-tbrowser-in-windows-powershell/38024)

<div class="topic-metadata">

**Author:** [@ygangy](https://root-forum.cern.ch/u/ygangy)\
**Replies:** 2\
**Last updated:** [February 18, 2020, 1:24pm UTC](https://root-forum.cern.ch/t/cant-open-tbrowser-in-windows-powershell/38024 "2020-02-18T13:24:57Z")

</div>

I connected to a Linux server through ssh from Windows Powershell, but after typing ‘new TBrowser’ on the terminal, no browser appeared. As a newbie, this feels tricky, and if it can be solved, I will be very grateful…

---

## [Histogram from TTree from TFile](https://root-forum.cern.ch/t/histogram-from-ttree-from-tfile/38178)

<div class="topic-metadata">

**Author:** [@kevinlinxc](https://root-forum.cern.ch/u/kevinlinxc)\
**Replies:** 7\
**Last updated:** [March 4, 2020, 2:10pm UTC](https://root-forum.cern.ch/t/histogram-from-ttree-from-tfile/38178 "2020-03-04T14:10:09Z")

</div>

It’s my first couple of days using ROOT. I’ve been instructed to make a histogram (I think it’s a histogram), make a gaussian fit to a peak, and then integrate it to get a value. Here’s what I’ve tried: TFile\* f = new…

---

## [Root crashes after fitting/iterating on some histograms](https://root-forum.cern.ch/t/root-crashes-after-fitting-iterating-on-some-histograms/38224)

<div class="topic-metadata">

**Author:** [@kevinlinxc](https://root-forum.cern.ch/u/kevinlinxc)\
**Replies:** 3\
**Last updated:** [March 3, 2020, 12:41pm UTC](https://root-forum.cern.ch/t/root-crashes-after-fitting-iterating-on-some-histograms/38224 "2020-03-03T12:41:17Z")

</div>

I have a directory of root files. I have a macro that is supposed to iterate over them, doing the following for each: Create a histogram, fit a gaussian function, integrate the fit function and print out the value. Wh…

---

## [Turn off error messages from TF1::GetX()](https://root-forum.cern.ch/t/turn-off-error-messages-from-tf1-getx/38175)

<div class="topic-metadata">

**Author:** [@marini](https://root-forum.cern.ch/u/marini)\
**Replies:** 2\
**Last updated:** [February 28, 2020, 10:22am UTC](https://root-forum.cern.ch/t/turn-off-error-messages-from-tf1-getx/38175 "2020-02-28T10:22:40Z")

</div>

Dear rooters, I use TF1::GetX(yvalue, xmin, xmax) to find the x corresponding to a certain yvalue of my TF1 within the \[xmin,xmax\] interval. I know that sometimes the x corresponding to the fvalue does not exits in the …

---

## [Root latest release upgrade](https://root-forum.cern.ch/t/root-latest-release-upgrade/38183)

<div class="topic-metadata">

**Author:** [@Akash116](https://root-forum.cern.ch/u/Akash116)\
**Replies:** 1\
**Last updated:** [February 27, 2020, 9:40pm UTC](https://root-forum.cern.ch/t/root-latest-release-upgrade/38183 "2020-02-27T21:40:34Z")

</div>

Hi Root just had its latest release of 6.20. How do I update it? is there a cmd code to upgrade or do I have to download the whole thing again and replace?\_\_\_ Please read tips for efficient and successful posting and p…

---

## [Plotting dx error bars intead of dy error bars](https://root-forum.cern.ch/t/plotting-dx-error-bars-intead-of-dy-error-bars/38164)

<div class="topic-metadata">

**Author:** [@luiz\_iniciante](https://root-forum.cern.ch/u/luiz_iniciante)\
**Replies:** 2\
**Last updated:** [February 27, 2020, 11:52am UTC](https://root-forum.cern.ch/t/plotting-dx-error-bars-intead-of-dy-error-bars/38164 "2020-02-27T11:52:16Z")

</div>

Dear Colleagues, Thanks for all the previous questions. This one relates to how to plot an n-tuple with error bars. I borrowed from this earlier post to write the attached code. The key lines are these: Long64\_t N…

---

## [Conditions on parameters in TF1 fit](https://root-forum.cern.ch/t/conditions-on-parameters-in-tf1-fit/38098)

<div class="topic-metadata">

**Author:** [@jwruss](https://root-forum.cern.ch/u/jwruss)\
**Replies:** 6\
**Last updated:** [February 27, 2020, 8:59am UTC](https://root-forum.cern.ch/t/conditions-on-parameters-in-tf1-fit/38098 "2020-02-27T08:59:01Z")

</div>

So I would like to fit a normalized histogram corresponding to a superposition of two probability distributions, let’s call them f\_1 and f\_2. As a TF1 object, let’s write this as TF1 probFit("probFit", "\[0\] \* f\_1(\[1\] + …

---

## [Unable extract correct data from Hits tree of ROOT file obtained from GATE simulation](https://root-forum.cern.ch/t/unable-extract-correct-data-from-hits-tree-of-root-file-obtained-from-gate-simulation/38030)

<div class="topic-metadata">

**Author:** [@Satyajit](https://root-forum.cern.ch/u/Satyajit)\
**Replies:** 4\
**Last updated:** [February 25, 2020, 11:37pm UTC](https://root-forum.cern.ch/t/unable-extract-correct-data-from-hits-tree-of-root-file-obtained-from-gate-simulation/38030 "2020-02-25T23:37:16Z")

</div>

Please read tips for efficient and successful posting and posting code ROOT Version: 6.16 Platform: Ubuntu 18.04.3 LTS Compiler: g++ I am new in ROOT. I want to analyse a root output file obtained from GATE (Geant4…

---

## [Using the skew normal distribution or Owen's T function](https://root-forum.cern.ch/t/using-the-skew-normal-distribution-or-owens-t-function/38132)

<div class="topic-metadata">

**Author:** [@jwruss](https://root-forum.cern.ch/u/jwruss)\
**Replies:** 1\
**Last updated:** [February 25, 2020, 2:34pm UTC](https://root-forum.cern.ch/t/using-the-skew-normal-distribution-or-owens-t-function/38132 "2020-02-25T14:34:54Z")

</div>

Hello, I was looking into using either the skew normal distribution or Owen’s T function with TF1 and I found your page https://sft.its.cern.ch/jira/browse/ROOT-5106. From the page it looks like it should now be support…

---

## [TSpline3 interpolation](https://root-forum.cern.ch/t/tspline3-interpolation/38089)

<div class="topic-metadata">

**Author:** [@TimFulcher](https://root-forum.cern.ch/u/TimFulcher)\
**Replies:** 2\
**Last updated:** [February 25, 2020, 8:03am UTC](https://root-forum.cern.ch/t/tspline3-interpolation/38089 "2020-02-25T08:03:05Z")

</div>

Hi all, thanks to help on these forums I’m getting close to what I want or need. I have my code displaying a histogram from root and I’m able to use a cubic spline to fit that histogram (code below). But now I need to…

---

## [PYTHIA 8 for ROOT](https://root-forum.cern.ch/t/pythia-8-for-root/38127)

<div class="topic-metadata">

**Author:** [@MicheleP](https://root-forum.cern.ch/u/MicheleP)\
**Replies:** 32\
**Last updated:** [February 24, 2020, 8:52pm UTC](https://root-forum.cern.ch/t/pythia-8-for-root/38127 "2020-02-24T20:52:56Z")

</div>

Please read tips for efficient and successful posting and posting code ROOT Version: Platform: MacOS Mojave Compiler: XCODE Hy everybody, I downloaded PYTHIA 8 and I’d like to use it as a ROOT 6 plug in. My ROOY …

---

## [Can not plot graph?](https://root-forum.cern.ch/t/can-not-plot-graph/38079)

<div class="topic-metadata">

**Author:** [@hammiu](https://root-forum.cern.ch/u/hammiu)\
**Replies:** 2\
**Last updated:** [February 24, 2020, 7:07am UTC](https://root-forum.cern.ch/t/can-not-plot-graph/38079 "2020-02-24T07:07:02Z")

</div>

Can you help me? I write code in VSCode and build project with Cmake. If i put function int main(), graph can not plot. And in different case, i ignore function int main(), it works normally. #include "TF1.h" int main(…

---

## [How to contribute to ROOT?](https://root-forum.cern.ch/t/how-to-contribute-to-root/38100)

<div class="topic-metadata">

**Author:** [@ahmat](https://root-forum.cern.ch/u/ahmat)\
**Replies:** 1\
**Last updated:** [February 23, 2020, 7:15pm UTC](https://root-forum.cern.ch/t/how-to-contribute-to-root/38100 "2020-02-23T19:15:21Z")

</div>

Hi everyone, I am Ahmat, currently pursuing BEng. in Statistics and I am new to ROOT. I want to be part of this community and contribute as a GSOC 2020 student and beyond. I have installed the ROOT software, forked the…

---

## [Linker Error if compiling a simple graph in VS](https://root-forum.cern.ch/t/linker-error-if-compiling-a-simple-graph-in-vs/38080)

<div class="topic-metadata">

**Author:** [@Lothar\_Kaps](https://root-forum.cern.ch/u/Lothar_Kaps)\
**Replies:** 9\
**Last updated:** [February 21, 2020, 1:46pm UTC](https://root-forum.cern.ch/t/linker-error-if-compiling-a-simple-graph-in-vs/38080 "2020-02-21T13:46:05Z")

</div>

Hello everyone, I have copied an easy example to test my root linkage thats been managed through cmake. Cmake did not give me any errors, so I assume the setup worked. However, if I am compiling the following code, VS20…

---

## [Fit data is empty despite presence of histogram](https://root-forum.cern.ch/t/fit-data-is-empty-despite-presence-of-histogram/38069)

<div class="topic-metadata">

**Author:** [@tk231](https://root-forum.cern.ch/u/tk231)\
**Replies:** 2\
**Last updated:** [February 20, 2020, 5:35pm UTC](https://root-forum.cern.ch/t/fit-data-is-empty-despite-presence-of-histogram/38069 "2020-02-20T17:35:40Z")

</div>

Hi! I’m attempting to modify the example code, langaus.c found on this page, so it may use the histogram that I have on hand (not filling it out bin by bin). So far, the only parts of the code that I have modified are a…

---

## [How to teach ROOT to colour in between the lines in graphs?](https://root-forum.cern.ch/t/how-to-teach-root-to-colour-in-between-the-lines-in-graphs/38059)

<div class="topic-metadata">

**Author:** [@JackLindon](https://root-forum.cern.ch/u/JackLindon)\
**Replies:** 13\
**Last updated:** [February 20, 2020, 4:39pm UTC](https://root-forum.cern.ch/t/how-to-teach-root-to-colour-in-between-the-lines-in-graphs/38059 "2020-02-20T16:39:24Z")

</div>

The following code should plot a straight line (which it does): void plotTest(){ TCanvas \*c1 = new TCanvas("c1","c1",200,10,700,500); double x\[11\] = {0,1,2,3,4,5,6,7,8,9,10}; double y\[11\] = {0,1,2,3,4,5,6,7,8,9,10};…

[Previous page](https://root-forum.cern.ch/c/newbie/26.md?page=100)

[Next page](https://root-forum.cern.ch/c/newbie/26.md?page=102)
