pp.smallSelect {pprobeSup}R Documentation

Careful selection of active assets

Description

Goes to some effort to select the subset of the assets of a certain size that are the best in the optimization.

Usage

pp.smallSelect(prices, port.size, ..., sets = 10, 
	finalStringency = 2)

Arguments

prices

named numeric vector of the prices to use in the optimization.

port.size

the exact number of assets that are to be in the portfolio. This is presumably a small positive integer.

...

the rest of the arguments that define the optimization.

sets

the number of unique combinations of assets to create and test.

The full name of this argument must be given since it is after the dot-dot-dot argument.

finalStringency

the value of stringency to use when optimizing the problem given each specific set of assets.

The full name of this argument must be given since it is after the dot-dot-dot argument.

Value

a list with the following components:

optimum

the result of trade.optimizer for the best optimization found.

sets

a sets by port.size matrix giving the assets in each selected set.

call

an image of the call that created the object.

Details

There are two stages. The first stage does sets optimizations where each optimization will not select any of the exact subsets that have already been selected.

The second stage again does sets optimizations but now the assets are specified so there is no selection aspect to the optimization. These optimizations set stringency to finalStringency.

The application that led to this function was looking for 3 to 6 assets in the portfolio, and it was quite desirable to have the best selection.

Testing status

In test suite, mildly tested.

Revision

This help file was last revised 2013 May 02.

See Also

trade.optimizer.

Examples

# attach data
require(pprobeData)

# select best three assets out of 100
# a real problem would hopefully have a better expected return

ones <- xassetPrices[1, 1:100]
ones[] <- 1
bestThree <- pp.smallSelect(prices=ones,
	variance=var(xassetPrices[1:500, 1:100]),
        expected.return=colMeans(xassetLogReturns[1:500,1:100]), 
	gross=10000 + c(-.5, .5), long.only=TRUE, max.weight=.5, 
	port.size=3)

# look at the good asset combinations
bestThree$sets
sort(table(bestThree$sets))

[Package pprobeSup version 1.00 Index]