ObjectiveParameters {farmR} | R Documentation |
Create ObjectiveParameters objects from xml files or from the defaults
ObjectiveParameters(file = defaultArableObjectiveParameters()) setWeightForObjective(params,objective,value) getWeightForObjective(params,objective)
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. |
Parses the xml document provided and stores it internally as a java object. The raw xml can be viewed using the show
command
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
Ira Cooke
parameters=ObjectiveParameters() show(parameters) names=objectiveNames(parameters) weights=sapply(names,function(x) getWeightForObjective(parameters,x))