Changeset 18114 for branches/3140_NumberSymbol/HeuristicLab.Algorithms.DataAnalysis/3.4/NonlinearRegression/NonlinearRegression.cs
- Timestamp:
- 12/13/21 10:25:35 (2 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/3140_NumberSymbol/HeuristicLab.Algorithms.DataAnalysis/3.4/NonlinearRegression/NonlinearRegression.cs
r18113 r18114 123 123 : base() { 124 124 Problem = new RegressionProblem(); 125 Parameters.Add(new FixedValueParameter<StringValue>(ModelStructureParameterName, "The function for which the parameters must be fit (only numeric constants are tuned).", new StringValue("<num> * x*x + 0.0")));126 Parameters.Add(new FixedValueParameter<IntValue>(IterationsParameterName, "The maximum number of iterations for constantsoptimization.", new IntValue(200)));125 Parameters.Add(new FixedValueParameter<StringValue>(ModelStructureParameterName, "The expression for which the <num> parameters should be fit.", new StringValue("<num> * x*x + 0.0"))); 126 Parameters.Add(new FixedValueParameter<IntValue>(IterationsParameterName, "The maximum number of iterations for parameter optimization.", new IntValue(200))); 127 127 Parameters.Add(new FixedValueParameter<IntValue>(RestartsParameterName, "The number of independent random restarts (>0)", new IntValue(10))); 128 128 Parameters.Add(new FixedValueParameter<IntValue>(SeedParameterName, "The PRNG seed value.", new IntValue())); … … 210 210 211 211 /// <summary> 212 /// Fits a model to the data by optimizing the numeric constants.212 /// Fits a model to the data by optimizing parameters. 213 213 /// Model is specified as infix expression containing variable names and numbers. 214 /// The starting point for the numeric constants is initialized randomly if a random number generator is specified (~N(0,1)). Otherwise the user specified constants are214 /// The starting values for the parameters are initialized randomly if a random number generator is specified (~N(0,1)). Otherwise the user specified values are 215 215 /// used as a starting point. 216 216 /// </summary>- 217 217 /// <param name="problemData">Training and test data</param> 218 218 /// <param name="modelStructure">The function as infix expression</param> 219 /// <param name="maxIterations">Number of constant optimization iterations (using Levenberg-Marquardt algorithm)</param>220 /// <param name="random">Optional random number generator for random initialization of numeric constants.</param>219 /// <param name="maxIterations">Number of Levenberg-Marquardt iterations</param> 220 /// <param name="random">Optional random number generator for random initialization of parameters.</param> 221 221 /// <returns></returns> 222 222 public static ISymbolicRegressionSolution CreateRegressionSolution(IRegressionProblemData problemData, string modelStructure, int maxIterations, bool applyLinearScaling, IRandom rand = null) { … … 265 265 if (!SymbolicRegressionParameterOptimizationEvaluator.CanOptimizeParameters(tree)) throw new ArgumentException("The optimizer does not support the specified model structure."); 266 266 267 // initialize constants randomly267 // initialize parameters randomly 268 268 if (rand != null) { 269 269 foreach (var node in tree.IterateNodesPrefix().OfType<NumberTreeNode>()) {
Note: See TracChangeset
for help on using the changeset viewer.