# turf.args: Arguments used in TURF Analysis In turfR: TURF Analysis for R

## Description

INTERNAL: A list of named arguments that can be passed into `turf` and `turf.combos` to control the behavior and output of the TURF algorithm.

## Usage

 `1` ```turf.args(depth=1L, keep=0, mc=FALSE, nsims=10000, psims=NULL, sort="d") ```

## Arguments

 `depth` Scalar indicating depth of reach, see Markowitz (2005). `depth` is an integer, greater than or equal to 1; non-integer values are coerced using `floor(depth)`. `keep` Scalar indicating the number of combinations of each size to keep in the output object generated by `turf`. `keep` is an integer, greater than or equal to zero; non-integer values are coerced using `floor(keep)`. If `keep` == 0 (default), all combinations evaluated by the TURF algorithm are kept; if `keep` >= 1, the lesser of `keep` or the number of evaluated combinations of a given size are kept. `mc` Logical indicating whether or not Monte Carlo simulated subsets of combinations should be substituted for all possible combinations of n choose k or user-specified combinations. When TRUE, subsets are generated using the method described by Adler, et al. (2010), only when `nsims` is also less than n choose k or the number of user-specified combinations. `nsims` Scalar indicating the number of combination sets of a given size to generate when `mc` == TRUE. `nsims` is an integer, greater than or equal to 1; non-integer values are coerced using `floor(nsims)`. This argument is ignored when `mc` == FALSE. `psims` Vector of length n indicating the probabilities of sampling each item into a combination set when `mc` == TRUE. Probabilities need not sum to 1 (see `sample` for additional details). All values must be greater than or equal to 0; for combinations of size k, there must be at least k non-zero values in `psims`. Default varies depending on calling function; when called from `turf`, default is the probability of each item being reached; when called from `turf.combos`, default is `rep(1/n, n)`. `psims` is ignored when `mc` == FALSE. `sort` Character indicating sort order of TURF output: "d" (default) causes combinations to be sorted in descending order of reach, then frequency; "a" causes combinations to be sorted in ascending order of reach, then frequency; "n" leaves combinations unsorted (i.e., they remain in the same order as the rows in each element of `combos`). `sort` is executed before `keep`. When `sort` == "n", `keep` is ignored (i.e., all combinations evaluated are kept in the output). No other values are permitted.

## Details

Defaults set by this function may be modified by specifying any of the arguments as name-value pairs in place of the `(...)` argument when calling `turf` or `turf.combos`. It is never necessary to call `turf.args` directly.

## Value

A list consisting of the named arguments.

## References

Adler, T.J., Smith, C. & Dumont, J. 2010. Optimizing product portfolios using discrete choice modeling and TURF. In: S. Hess, A. Daly (Eds), Choice modeling: the state-of-the-art and the state-of-practice; proceedings from the Inaugural International Choice Modeling Conference. Emerald Publishing Group Ltd., pp. 485-497.

Krieger, A.M. & Green, P.E. 2000. Turf revisited: Enhancements to toal unduplicated reach and frequency analysis. Marketing Research, 12, 30-36.

Markowitz, L. 2005. Going beyond TURF to complement and extend existing product lines. Ipsos-Insight, November 2005.

Miaoulis, G., Free, V. & Parsons, H. 1990. TURF: A new planning approach for product line extensions. Marketing Research, March, pp. 28-40.

## Examples

 ```1 2``` ``` ##INTERNAL USE ONLY ```

### Example output

```Loading required package: dplyr

Attaching package: 'dplyr'

The following objects are masked from 'package:stats':

filter, lag

The following objects are masked from 'package:base':

intersect, setdiff, setequal, union
```

turfR documentation built on May 2, 2019, 3:21 a.m.