Locked History Actions

Diff for "ANAROOT/Manual/HowTo"

Differences between revisions 2 and 3
Deletions are marked like this. Additions are marked like this.
Line 3: Line 3:
<<TableOfContents(3)>> <<TableOfContents(4)>>

=== anarootにログイン(仮) ===
{{{
$ anarootlogin username
$ root -l
root[i] .x hoge.C (マクロを実行)
root[i] .q (rootを終了)
}}}

=== anafile書き方 ===
==== anapawのanafileと変えたところ ====
・2Dで今までは
{{{
"IDx" "IDy" "binx" "biny"
}}}
の順だったのを
{{{
"IDx" "binx" "IDy" "biny"
}}}
にした。

・処理方法を先に書いて続く行を処理 -> 一行ごとに処理

・analyserやstopに非対応。stopの代わりにanaloopを継承したクラスで直接
{{{
if(hoge) return;
}}}
を書いて途中で抜けてください。

==== 文法 ====
{{{
<hoge>: 続く文字の処理を指定。何も書かない場合はhistogramの定義と見なされる。
100,: 数字の後ろ「のみ」ついてカンマを「必ず」書くこと。カンマの数が適切でない場合に怒られます。
"title": 大体においてobjectのtitleになります。
}}}

==== 具体例 ====
{{{
# 1D
gate, analyser,index_start,index_end,wnum, bin#,low,up, "title"
# 2D
gate, analyser,index_start,index_end,wnum, bin#,low,up, analyser,...,up, "title"
}}}

=== analoop書き方 ===
valに詰める -> Add関数
このときanapawではデータが無いときに非物理量(-1000等)を詰めていたが、
anarootではAddしなければhistogramにはfillされない。
例えばTDCのover flowを詰めたいのなら詰めて構わないがその分パフォーマンスは落ちる。
Line 19: Line 69:
みたいな感じですか? (2012 2/14 田中)

使い方についてざっくばらんに

anarootにログイン(仮)

$ anarootlogin username
$ root -l
root[i] .x hoge.C (マクロを実行)
root[i] .q (rootを終了)

anafile書き方

anapawのanafileと変えたところ

・2Dで今までは

"IDx" "IDy" "binx" "biny"

の順だったのを

"IDx" "binx" "IDy" "biny"

にした。

・処理方法を先に書いて続く行を処理 -> 一行ごとに処理

・analyserやstopに非対応。stopの代わりにanaloopを継承したクラスで直接

if(hoge) return;

を書いて途中で抜けてください。

文法

<hoge>: 続く文字の処理を指定。何も書かない場合はhistogramの定義と見なされる。
100,: 数字の後ろ「のみ」ついてカンマを「必ず」書くこと。カンマの数が適切でない場合に怒られます。
"title": 大体においてobjectのtitleになります。

具体例

# 1D
gate, analyser,index_start,index_end,wnum, bin#,low,up, "title"
# 2D
gate, analyser,index_start,index_end,wnum, bin#,low,up, analyser,...,up, "title"

analoop書き方

valに詰める -> Add関数 このときanapawではデータが無いときに非物理量(-1000等)を詰めていたが、 anarootではAddしなければhistogramにはfillされない。 例えばTDCのover flowを詰めたいのなら詰めて構わないがその分パフォーマンスは落ちる。

ridfを解析する場合

book(new TArtAnaLoopExample, "ana/example.ana");
push("ridf/run0001.ridf");
start();
status();
ls();

histの保存・読み込み

...
hstore("hist.root"); // 保存
fetch("hist.root"); // 読み込み