ng0177 has asked for the wisdom of the Perl Monks concerning the following question:
rather than resorting to anything else, I would like to write a data manipulation script in perl. The task is as follows, see attached data file:
1. find and read vector of 36 (or n) values Opt.OptGBM.Parameters starting with 0.1
2. overwrite 36 (or n) numbered triple line block lower and upper values of Opt.OptGBM.Design.OptParam.001.Name with a percentage e.g. +/- 10% of the vector value for
lower: vector*(1+vector*percentage) and
upper: vector*(1-vector*percentage)
I can go ahead and refresh my knowledge, if anyone may give some guidance.
Appreciate, Thomas
... ... Opt.OptGBM.Parameters = 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1. +2 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 0.1 0.2 0.3 0.4 0.5 + 0.6 0.7 0.8 0.9 1.0 1.1 1.2 ... ... Opt.OptGBM.Design.OptParam.001.Name = RadialTurbine.Ge +o.Wheel.Blade.Hub.Theta.Point.1.Y.Opt Opt.OptGBM.Design.OptParam.001.LowerLimitFormula = -1. Opt.OptGBM.Design.OptParam.001.UpperLimitFormula = 2. Opt.OptGBM.Design.OptParam.002.Name = RadialTurbine.Ge +o.Wheel.Blade.Hub.Theta.Point.2.Y.Opt Opt.OptGBM.Design.OptParam.001.LowerLimitFormula = -1. Opt.OptGBM.Design.OptParam.001.UpperLimitFormula = 2. ... ...
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: data manipulation
by BillKSmith (Monsignor) on Feb 28, 2021 at 21:27 UTC | |
|
Re: data manipulation
by kcott (Archbishop) on Feb 28, 2021 at 17:13 UTC |