Advanced Octave A30 — Interpretable statistical reports

by Giux GX-TXT, octave-en, scripts-en 2 min read

Advanced GNU Octave with GX-TXT · Module 05

A numerical result is not a complete relationship until it is clear meaning, unity, hypotheses and applicable fields. GX-TXT offers a semantic service that interprets existing numerical results without repeating the calculation.

Objectives and prerequisites

We repeat statistics and uncertainties of previous lessons and the introductory course. We build a summary of five synthetic values in volts; they are not experimental measures. The test uses GX-TXT dev112-P011-bis and GNU Octave 9.4.0.

From calculation to meaning

Import rapporto_semantico.m, register it and run it with the Runner.

x = [9.8,10.1,10.0,10.2,9.9];
stats = gxtxt_api_call('NUMERIC_API_v1','statistics',{x});
context = struct('y_unit','V','sampling_model','independent_observations', ...
                 'mean_se_model','sampling');
semantic = gxtxt_api_call('STATISTICAL_RESULT_SEMANTICS_API_v1','from_numeric', ...
                         {'math.numeric.summary','statistics',stats,context});
report = gxtxt_api_call('STATISTICAL_RESULT_SEMANTICS_API_v1','report',{semantic});

statistics produces the numerical result; from_numeric adapts it to the declared meaning profile, with explicit sampling units and hypotheses. report returns a textual representation. The hypothesis of independent observations is a choice of the didactic model: it is not automatically demonstrated by the API.

In the test, the default ratio indicates five observations and reports that various fields relating to residues are not applicable, because a residual model has not been provided here. It doesn’t bring those values like zero. The report shown does not automatically include all calculated statistics: choose and explicitly verify the quantities required for your audience according to the documentation of the version used.

Building a Scientific Report

A document intended for others should indicate source and identity of data, method, unit, estimates, uncertainties available, hypotheses and limits. If a range is not available, write it: do not invent it from the standard error only. Keep separate observations, estimates and interpretation and preserves version of the software and code necessary to repeat the analysis.

The semantic service interprets the results it receives; it does not verify alone that the sample is representative or that the scientific model is correct. The final statements remain the responsibility of those who conduct the analysis.

Exercise

  1. Why does the report not give a numerical value to the residues in this example?
  2. Is the independent_observations hypothesis tested by the API call?
  3. Why not replace an unavailable range with [0,0]?

Worked solution

  1. It is a descriptive summary without a pattern of declared residues.
  2. No. It is a hypothesis provided by the script that must be justified in relation to the data.
  3. Because zero would be a invented value and would communicate an unsupported certainty.

Download the Module 05 scripts (ZIP)

#GNU Octave #GX-TXT #GX-TXT public APIs

Other steps of this project

Leave a Reply

Your email address will not be published. Required fields are marked *