In order to create a new or modify an existing Frequency analysis, the following analysis properties are defined:
Analysis Properties
- Type — “Frequency” (needed only if “new” is “true”)
- Name — the name of the new Frequency analysis or the name of an existing Frequency to modify
- New — “true” (needed to define a new Frequency analysis)
- Modify — “true” (needed to modify an existing Frequency analysis)
InputDataProperties needs to be defined if this is a “new” analysis. InputDataProperties takes a database, table, and a list of columns. If the analysis is being modified, the InputDataProperties can be redefined. They will replace the existing set of columns that were originally defined for the analysis.
Column Input Data (must be defined for any ‘frequency style’)
- Database — the name of the database
- Table — the name of the table
-
Columns — a list of column names
- Name — the name of the column
An XML example to define columns for a new analysis follows.
<InputDataProperties> Database="twm_source" Table="twm_customer"> <Columns> <Column name="age"/> <Column name="income"/> </Columns> </InputDataProperties>
Statistics Column Input Data (optional for frequencyStyle=”basic”)
-
Statistics Columns — a list of column names of numeric or date type
- Name — the name of the column to collect statistics on
An XML example to define Columns and StatisticsColumns when frequencyStyle=”basic” follows.
<InputDataProperties> Database="twm_source" Table="twm_customer"> <Columns> <Column name="age"/> <Column name="income"/> </Columns> <StatisticsColumns> <StatisticsColumn name="nbr_children"/> <StatisticsColumn name="years_with_bank"/> </StatisticsColumns> </InputDataProperties>
Pairwise Column Input Data (optional for frequency style=”pairwise”)
-
Pairwise Columns — a list of column names
- Name — the name of the pairwise column
An XML example to define Columns and PairwiseColumns when frequencyStyle=”pairwise” follows.
<InputDataProperties> Database="twm_source" Table="twm_customer"> <Columns> <Column name="age"/> <Column name="income"/> </Columns> <PairwiseColumns> <PairwiseColumn name="nbr_children"/> <PairwiseColumn name="years_with_bank"/> </PairwiseColumns> </InputDataProperties> Input Data Analysis properties can be specified to override the default values for a new frequency analysis or to modify the values of an existing frequency analysis.
Input Data Analysis Properties
- FrequencyStyle — “basic”, “pairwise”, or “crosstab”. Default is “basic”
- IncludeMinimumPercent — “true” or “false”. Default is false.
- MinimumFrequencyToReturn (defined only if IncludeMinimumPercent=”true”) — the decimal or integer value of the minimum frequency to return
- IncludeCumulativeMeasures — “true” or “false”. Default is false.
- TopRankingResultsToReturn (defined only if IncludeCumulativeMeasures=”true”) — the integer value of the top ranking results to return
An XML example to define InputDataAnalysis properties follows.
<InputDataAnalysisProperties frequencyStyle=”basic” includeMinimumPercent="true" minimumFrequencyToReturn=”1.5" includeCumulativeMeasures="true" topRankingResultsToReturn=”50"/>
Output Properties
For the definition of output properties, see Modifying Output Batch Properties And Post Processing Properties.
Expert Properties
- WhereClause — the where clause to be defined
- HavingClause — the having clause to be defined (only valid if IncludeMinimumPercent is not set to “true”)
- QualifyClause — the qualify clause to be defined (only valid if IncludeCumulativeMeasures=”true” and TopRankingResultsToReturn is not set)
An XML example to define Expert properties follows.
<ExpertProperties> whereClause=”age>50”/>
Sample XML Definition for a Frequency Analysis
<Analysis name="MyFrequency" type="Frequency" new="true"> <InputDataProperties Database="twm_source" Table=”twm_customer” <Columns> <Column name=”age”/> <Column name=”income”/> </Columns> <PairwiseColumns> <PairwiseColumn name=”nbr_children”/> <PairwiseColumn name=”years_with_bank”/> </PairwiseColumns> </InputDataProperties> <InputDataAnalysisProperties FrequencyStyle=”pairwise” IncludeMinimumPercent=”true” MinimumFrequencyToReturn=”2.5”/> <OutputProperties> outputStyle="CreateTable" outputDatabase="twm_results" outpuName="MyFrequencyOutput" </OutputProperties> </Analysis>