This program demonstrates simultaneous update of histogram and fitted function.
Every second new random entries add and histogram fitted again. Required at least JSROOT version 5.1.1 to see correct fit function update in browser
void histfitserver(void)
{
auto h1 =
new TH1F(
"h1",
"histogram 1", 100, -5, 5);
auto f1 =
new TF1(
"f1",
"gaus", -10, 10);
while (!
gSystem->ProcessEvents()) {
h1->FillRandom(
"gaus", 100);
}
}
1-D histogram with a float per channel (see TH1 documentation)
Online http server for arbitrary ROOT application.
- Author
- Sergey Linev
Definition in file histfitserver.C.