Please fill also the fields below. Note that root -b -q will tell you this info, and starting from 6.28/06 upwards, you can call .forum bug from the ROOT prompt to pre-populate a topic.
I cannot reproduce your problem - for me both results are the same. I am using version 6.30.04 on a Macbook. Which OS are you using and how have you installed ROOT?
What I do step by step is:
1. g++ -o test df001.cpp `root-config --cflags --libs`
2. ./test
OUTPUT:
2 entries passed all filters
5 entries passed the string filter
The mean is always included between the min and the max: 1 <= 2 <= 3
Selected b1 entries
0 1 2 3 4
The type of b1Vec is vector<double>
Filled h 5 times, mean: 2
Filled h with 5 entries
Events passing cutb1: 5
Events passing cutb1b2: 2
Events passing both: 2
8
8
Entry: 0 Slot: 0
Entry: 1 Slot: 0
Entry: 2 Slot: 0
Entry: 3 Slot: 0
Entry: 4 Slot: 0
Entry: 5 Slot: 0
Entry: 6 Slot: 0
Entry: 7 Slot: 0
Entry: 8 Slot: 0
Entry: 9 Slot: 0
and when I run the tutorial:
1. root df001_introduction.C
OUTPUT:
2 entries passed all filters
5 entries passed the string filter
The mean is always included between the min and the max: 1 <= 2 <= 3
Selected b1 entries
0 1 2 3 4
The type of b1Vec is vector<double>
Filled h 5 times, mean: 2
Filled h with 5 entries
Events passing cutb1: 5
Events passing cutb1b2: 2
Events passing both: 2
8
8
Entry: 0 Slot: 0
Entry: 1 Slot: 0
Entry: 2 Slot: 0
Entry: 3 Slot: 0
Entry: 4 Slot: 0
Entry: 5 Slot: 0
Entry: 6 Slot: 0
Entry: 7 Slot: 0
Entry: 8 Slot: 0
Entry: 9 Slot: 0
Thanks for reaching out to the forum! After a bit of debugging we discovered that the code of the tutorial responsible for writing out the example TTree was written in a way that subtly made assumptions on how different compilers would compile the code. A fix is on the way, I’ll link the PR here once I upload it.
The tutorial was updated a while back but I didn’t comment again on this post, apologies for that. Just for completeness, the version of the tutorial after the update can be found at ROOT: tutorials/dataframe/df001_introduction.C File Reference