Skip to content

Commit

Permalink
Statistical generator API doc and minor typo fix (#165)
Browse files Browse the repository at this point in the history
  • Loading branch information
JennaPaikowsky authored Oct 25, 2024
1 parent 38ba103 commit 17debe6
Show file tree
Hide file tree
Showing 2 changed files with 78 additions and 1 deletion.
2 changes: 1 addition & 1 deletion codegen/pyadritem.txt
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ class Item:


The type of the item created in the preceding code cannot be changed. However,
the attributes describing the object can be reset at any time. These hanges are
the attributes describing the object can be reset at any time. These changes are
automatically propagated into the database. The attributes described in the
following "Parameters" section can be used to control the rendering of these objects.

Expand Down
77 changes: 77 additions & 0 deletions doc/source/lowlevelapi/TemplateObjects.rst
Original file line number Diff line number Diff line change
Expand Up @@ -325,6 +325,9 @@ sqlqueries `SQL Query`_ :ref:`report_objects.sqlqu

treemerge `Tree Merge`_ :ref:`report_objects.mergetreeREST()
<mergetreeREST>`

statistical `Statistical Analysis`_ :ref:`report_objects.statisticalREST()
<statisticalREST>`
======================= ============================= ========================================


Expand Down Expand Up @@ -1691,3 +1694,77 @@ header.
Set the name of the tag to be used to generate an output tree header.
Input needs to be a string. An empty string (the default) specifies that
no tree header be generated.

.. _statisticalREST:

statisticalREST object
^^^^^^^^^^^^^^^^^^^^

Inherits from TemplateREST, GeneratorREST

Class that corresponds to the Statistical Analysis Generator
template type. Its specific methods are:

**template.get_analysis_type()**

Get the type of statistical analysis

**Template.set_analysis_type(value=””)**

Set the type of statistical analysis.
Only “Linear Regression” is supported.

**Template.get_table_name()**

Get the name of the output table.

**Template.set_table_name(value=””)**

Set the name of the output table. Input must be a string.

**Template.get_tree_name()**

Get the name of the output tree with statistical parameters values.

**Template.set_tree_name(value=””)**

Set the name of the output tree with statistical parameters values.
Input must be a string.

**Template.set_predictor_variables(value)**

Set the predictor variables. The input needs to be a list,
with each element a list of length 3.
The elements of the sub-lists must be:

- Type. Only “row” is currently supported.
- Variable predictor name.
- Output row name.

**Template.get_predictor_variables()**

Get the list of predictor variables.
Returns a list where each element is a sub-list of
3 elements (type, predictor name, output name)

**Template.set_response_variables(value=””)**

Set the response variables. Input must be a list of sub-lists,
each with two elements:

- Response variable name
- Output row name

**Template.get_response_variables()**

Get the response variable list. Each element is a sub-list
with two elements each.

**Template.set_analysis_params(value=””)**

Set the parameters for the statistical analysis.
Currently not supported.

**Template.get_analysis_params()**

Get the parameters for the statistical algorithm.

0 comments on commit 17debe6

Please sign in to comment.