ObjectiveParameters {farmR}R Documentation

Create ObjectiveParameters objects

Description

Create ObjectiveParameters objects from xml files or from the defaults

Usage

ObjectiveParameters(file = defaultArableObjectiveParameters())
setWeightForObjective(params,objective,value)
getWeightForObjective(params,objective)

Arguments

file A character string with the full path to an xml document containing the parameters
params An ObjectiveParameters object
objective A character string identifying the objective. Available values can be obtained via objectiveNames(params)
value New weighting for objective. Objectives are renormalized so only the relative values assigned to different objectives are important.

Details

Parses the xml document provided and stores it internally as a java object. The raw xml can be viewed using the show command

Value

ObjectiveParameters returns an object of the class ObjectiveParameters getWeightForObjective returns the relative weight of the specified objective objectiveNames returns a string vector with the names of objectives

Author(s)

Ira Cooke

Examples

        parameters=ObjectiveParameters()
        show(parameters)
        
        names=objectiveNames(parameters)
        weights=sapply(names,function(x) getWeightForObjective(parameters,x))
        

[Package farmR version 1.0 Index]