Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

...

...

...

Info

View in Help Center (registration required)

...

Apply operations execute an operator selected by the user on the examples in the dataset. 

For example, you can compute the average of an attribute, which will then substitute the actual value in all patterns. When used together with grouping the apply operators may become very powerful.

Info

Changes you make can be committed run-time or on request.

Procedure

  1. Drag and drop the attribute in any cell of the Apply column.
    Image Modified

  2. Specify the operator to be used according to the type of the selected attribute.

  3. Click Ok.

The operators that can be used are the following:

Attribute type

Operator

Ordered attributes

  • Mean

  • Standard deviation

  • Median

  • Maximum

  • Minimum

  • Mode

  • Sum

  • Cumulative sum

  • Count (the number of examples)

  • Entropy

  • Enumerate

Nominal attributes

  • Mode

  • Maximum

  • Minimum

  • Entropy

  • Count (the number of examples)

  • Enumerate


Example

The following example is based on the Adult dataset.

Info

...

Sample Datasets

Scenario data can be found in

...

the /wiki/spaces/UM0302/pages/299794555 folder in your Rulex installation.

The apply operation becomes very useful and powerful when coupled with groups, where the selected operation is computed for each group independently.

In the following example, the workclass workclass attribute is grouped and subsequently the following apply operations are performed:

  • an apply operation on age that computes the average of that variable for each group,

  • an apply operation on fnlwgt that computes the number of patterns for each group (one of the few operators, along with Enumerate, that do not depend on the attribute on which they are computed) and

  • an apply operation on marital-

...

  • status that computes the mode on that variable for each group.

This allows to discover, in a single view, for example that the majority of State-gov workers has no family, that the most represented group is that of Private Private workers (with 22696 elements) and that Without-pay (47.8 years) and Self-emp-inc (46.0 years) are the oldest workers.

Image RemovedImage Added