close
Warning:
Can't synchronize with repository "(default)" ("(default)" is not readable or not a Git repository.). Look in the Trac log for more information.
- Timestamp:
-
Jun 13, 2017, 1:40:47 PM (7 years ago)
- Author:
-
Patrick Stowell
- Comment:
-
--
Legend:
- Unmodified
- Added
- Removed
- Modified
-
v12
|
v13
|
|
407 | 407 | |
408 | 408 | === Covariance Structure === |
| 409 | Covariance objects are used by NUISANCE to assign likelihood penalty terms to parameters as well as define appropriate parameter throws when studying systematic uncertainties. They can be specified in the card file by providing the 'covar' structure, plus an ID, input definition, and state. |
409 | 410 | {{{ |
410 | 411 | covar ID TYPE:INPUT STATE |
411 | 412 | }}} |
412 | | |
413 | | |
| 413 | - **ID** : Unique ID specified by the user so they can keep track of this covariance class in the output file. Saved objects from this covariance will be labeled 'ID_label' (e.g. ID_central). |
| 414 | - **TYPE** : Covariance type. There are multiple ways to define a covariance, with some examples of these types below. |
| 415 | - **INPUT** : Input definition, this depends a lot on what the **TYPE** is defined as. Some examples are below. |
| 416 | - **STATE** : State of this covariance, used to tell NUISANCE whether it should use it to apply a likelihood penalty (e.g. GAUSPULL), use it to throw parameters (e.g. GAUSTHROW), or both. |
| 417 | |
| 418 | ==== Single uncorrelated dial covariances ==== |
| 419 | To tell NUISANCE to make a covariance for a single dial, you can specifiy the covariance type as 'DIAL' |
414 | 420 | {{{ |
415 | 421 | covar ID DIAL:NAME;CENTRAL;WIDTH STATE |
416 | 422 | }}} |
417 | | |
418 | | |
| 423 | - **NAME** : Name of the RW dial. This dial should have also already been setup using one of the 'parameter' structures shown above. |
| 424 | - **CENTRAL** : Central value for this dial used in the covariance. For example when you want to include the result from a previous fit, this should be set to the best fit value from that fit. |
| 425 | - **WIDTH** : Error on the parameter about the central value. Used as the Gaussian width when generating parameter throws. For example when you want to include the result from a previous fit, this should be set to the best fit error from that fit. |
| 426 | |
| 427 | |
| 428 | ** Example 1 ** : Covariance used to throw MaCCQE uncorrelated in nuissyst using MaCCQE=0.0+-1.0 |
| 429 | {{{ |
| 430 | genie_parameter MaCCQE 0.0 -3.0 3.0 1.0 FREE |
| 431 | covar MaThrow DIAL:MaCCQE;0.0;1.0 GAUSTHROW |
| 432 | }}} |
| 433 | |
| 434 | ** Example 2 ** : Covariance used to apply an additional MaCCQE pull in nuismin using MaCCQE=0.0+-1.0 |
| 435 | {{{ |
| 436 | genie_parameter MaCCQE 0.0 -3.0 3.0 1.0 FREE |
| 437 | covar MaTPull DIAL:MaCCQE;0.0;1.0 GAUSPULL |
| 438 | }}} |
| 439 | |
| 440 | ==== Correlated dial covariances ==== |
| 441 | To tell NUISANCE to make a covariance for multiple parameters that have some correlations between the, you can specifiy the covariance type as 'ROOT' and provide a ROOT input file containing the covariaince |
419 | 442 | {{{ |
420 | 443 | covar ID ROOT:FILEPATH;DIAL_HIST;COVARIANCE_HIST STATE |
421 | 444 | }}} |
422 | | |
| 445 | - **FILEPATH** : Path to a ROOT file containing the covariance information |
| 446 | - **DIAL_HIST** : Name of a TH1D inside **FILEPATH**. This TH1D should be created such that each bin corresponds to a different dial, with the bin contents set to the best fit value for that dial, and the bin label set to the dial name. A good example of such a histogram is given in the standard output of nuismin called 'fit_dials'. |
| 447 | - **COVARIANCE_HIST** : Name of a TH2D inside **FILEPATH**. This TH2D should be created such that each bin in x and y corresponds to a different dial, with the bin contents set to the covariance between each dial according to the bins x and y position, and the bin labels set to the corresponding dial names. A good example of such a histogram is given in the standard output of nuismin called 'fit_dials_free'. |
| 448 | |
| 449 | The following examples assume you have a root histogram called myfitresult.root, containing a TH1D called 'fitresults' with the dial central values in it, and a TH2D covariance histogram called 'cov', and that both these histograms describe the central values and covariance for the 'MaCCQE' and 'MaCCRES' dials. |
| 450 | |
| 451 | ** Example 1 ** : Covariance ROOT file used to throw MaCCQE and MaCCRES using nuissyst |
| 452 | {{{ |
| 453 | genie_parameter MaCCQE 0.0 -3.0 3.0 1.0 FREE |
| 454 | genie_parameter MaCCRES 0.0 -3.0 3.0 1.0 FREE |
| 455 | covar CovarThrow ROOT:/path/to/myfitresult.root;fitresults;cov GAUSTHROW |
| 456 | }}} |
| 457 | |
| 458 | ** Example 1 ** : Covariance ROOT file used to apply a pull to MaCCQE and MaCCRES using nuismin, where fitresult.root is in the current directory |
| 459 | {{{ |
| 460 | genie_parameter MaCCQE 0.0 -3.0 3.0 1.0 FREE |
| 461 | genie_parameter MaCCRES 0.0 -3.0 3.0 1.0 FREE |
| 462 | covar CovarThrow ROOT:myfitresult.root;fitresults;cov GAUSPULL |
| 463 | }}} |
423 | 464 | |
424 | 465 | === Config Structure === |